Beginners - March 2015 (Page 2)

Questions about connect 4 board
 
Hi, So I am working on this connect four board stuff to test myself of some basic programming... And I got stuck on the idea of how to display the board(Note...
[8 replies] Last: If lastposition is supposed to record the users' X and O on the boar... (by fg109)
EOF
 
Hello, I need to verify that the expression getchar() ! = EOF is 0 or 1. My current code: #include <stdio.h> int main (int argc, char *argv ) ...
[4 replies] Last: You'll want to print a newline at the end of the printing within the l... (by Zhuge)
urgent help
 
solved
[1 reply] : help please (by sirrunrun)
minesweeper/GetPixel()
 
Hi, I'm trying to write a program that plays a minesweeper game by itself. I think I can write all of the code just fine, but I don't know how to have the pr...
[2 replies] Last: Microsoft Visual Studio 2013? (by aarjm123)
by Sev
Program immediately closes and expects a ";"
 
The program I wrote immediately closes //Game Over // My first program #include <iostream> int main() { std::cout << "Game Over!" << std::endl ...
[2 replies] Last: Thank you (by Sev)
by Sev
Program wont start "identifier 'end1' is undefined"
 
My program wont start up because of "end1" (Entirely new to C++ so forgive my simple mistakes) Program: //Game Over // My first program #include <iostream> ...
[4 replies] Last: Thank you very much (by Sev)
Battleship Game with Classes Help
 
delete
[no replies]
Determining if numbers are prime
 
I feel like I'm close to solving this, but I don't know what's wrong. I have to create a program that reads in 5 integers and determine if each is prime, then p...
[7 replies] Last: good to know, no problem x'D (by Gamer2015)
by as4mvp
Arrays with Random Numbers
 
Write a program in which you create an array with 250 elements. Populate the array with random real numbers between 1 and 100. Using the statistics library, cal...
[1 reply] : Using the statistics library What library does that refer to? wi... (by keskiverto)
Manipulating strings from a file
 
Hi all, second to last assignment for the semester! Thanks guys for all your help so far. This week I'm struggling to rewrite my last program so it does all the...
[1 reply] : Depending on how you're saving your data (how does it look in the save... (by fg109)
call parent function from overriding function in child
 
I have a class (child) that is inheriting from another class (parent). I'd like to create a function in the child class w/the same name and arguments as a func...
[6 replies] Last: so i think my code should look like this: class parent { public: in... (by joecooler)
Pointers to functions and vectors within vectors
 
Hi, I have created a class called Rows which has the following in it: #pragma once #include "Berths.h" #include "Ship.h" class Rows { public: Rows...
[7 replies] Last: Then your class hierarchy should look like this: class Ship { //... (by fg109)
Problem with Fibonacci's sequence and Binary search
 
So, I have a problem with the source code down there. As you can see, the program is used to search the Fibonacci sequence with the Binary search method. The pr...
[4 replies] Last: @windmilltaker Well, I did some more thinking and realized that wha... (by fg109)
Difficulty with ending loop/while statement
 
Hey guys, I am not sure why the loop will not close. Any ideas?? #include <cstdlib> #include <iostream> using namespace std; int main() { //define variables...
[2 replies] Last: I hate overlooking the small things... Thanks!! (by Comicalizard)
Files problem
 
I am trying to get this program to open the file and output the info onto the screen. I created a file on visual studio and another one on my desktop but both w...
[2 replies] Last: What I ended up doing was creating a text file in Visual Studio and sa... (by thebossman)
Guessing game help.
 
In the follow program, I am having an error when I write to an ouputfile. When my program asks the user for the name of the output file, it first says "Output f...
[5 replies] Last: Every time you use a cin >> in your program it leaves a "\n" in the in... (by Jims)
Multiple inputs from cin
 
I need two user inputs (int) to be pushed back into two different vectors respectively. What I have now is the first user input is pushed back into both vector...
[3 replies] Last: c1.push_back(i); //... c2.push_back(j); You are pushing back the ind... (by fg109)
Problem with...(well basically everything)
 
Hello I was writing a simple program,just to train so i've got a problem,here is code: #include<iostream> #include<fstream> #include<string> using ...
[2 replies] Last: Firstly, this doesn't compile for me. You're using a variable called ... (by SuperCrusader)
another pointer exercise again
 
Hi, i was dong next of my exercises and i kind of did it but again there were few questions that i was asking myself. If someone has some free time and likes p...
[6 replies] Last: @Lorence30 I don't think that's a logic error. The p pointer is supp... (by fg109)
File Editing
 
I made a program that allows the user to edit (or append to) a file they previously created. If the user enters a wrong name or misspells the file name, how wou...
[1 reply] : http://stackoverflow.com/questions/12774207/fastest-way-to-check-if-a-... (by fg109)
March 2015 Pages: 1234... 51
  Archived months: [feb2015] [apr2015]

This is an archived page. To post a new message, go to the current page.