Beginners - December 2011 (Page 29)

Battleship Program for C++
 
OK, I am stuck on a project for one of my classes and I was wondering if anyone could help. We are supposed to fill in certain functions in the following way an...
[1 reply] : Look at this for file handling: http://www.cplusplus.com/reference/ios... (by coder777)
Assistance with void function
 
# In the main * create a double and assigns it a value * create a pointer that points to the double * use a cout statement to display text descri...
[1 reply] : Is it something like *** void display(double* ptr, double x)**?? Yes,... (by coder777)
member function advice needed
 
im making an iterative program that uses an algorithm to update the elements of a matrix. I made the program in procedural/functional form before, but now i am ...
[1 reply] : A member functions don't differ from any other functions, except that ... (by coder777)
Pointer help please...
 
I'm dealing with an array of pointer structures and I'm very new to pointers. But my issue is specifically with void add(), since that's the only one I've got s...
[1 reply] : It seems to display what I think is the address of the array No, it's... (by coder777)
by Mob G
organizing code
 
New to C++ Could someone organize this code for me as a working line.h, line.cpp, and main.cpp?? thank you #ifndef LINE_H #define LINE_H #include "Poi...
[2 replies] Last: Okay, thanks for the tip... So the first part is the header file. I j... (by Mob G)
Problem with reading from a file and a c-string
 
This is the line the I'm trying to read from the "master" file: 5 Christine Kim (spaces) 30.00 2 1 F And this is the code that I'm using: master...
[3 replies] Last: or I could be dumb as a rock and read from the wrong file. that maste... (by MrBackpack)
class help
 
I am trying to print out the result of binary addition, but when I run the program nothing prints out. I have been stuck at this point for quite some time and ...
[no replies]
fstream pointer location is fubar
 
So, my code is convoluted and ridiculous so I won't post any code snippets. But to put it simply: My goal is to insert some text into a text file, in between...
[no replies]
Need help fixing code
 
I'm creating a code for guessing a random number that a user put in. I come across a problem where I ask the user if the number generated was their number, and ...
[3 replies] Last: except the <stdio.h> is pointless because <iostream> is the c++ equiva... (by Aramil of Elixia)
switching CLR cosnsol app to window forms app
 
Hi, I am currently using visual c++ 2008. I accidently created a project with CLR console application template, which I meant to create a project with window...
[no replies]
Help read file and write to new file
 
I need to write a program that reads from Statement.txt and write it to a new text file with proper header name and tab as delimiter. Display total amount on s...
[1 reply] : So what have you done so far? What do you need help with? (by ascii)
how do you turn a char into a string with a length of one
 
how do you turn a char into a string with a length of one?
[2 replies] Last: These also work: C++ char c = 'A'; // assignment method string s... (by Duthomhas)
by Hotice
using namespaces to access classes that are in separate files
 
Let's say you have a main() file, 8 separate cpp files, and 8 corresponding header files (that represent classes, of course) Is it possible to assign each cpp f...
[10 replies] Last: I am now trying to put them all into one big program, which has been d... (by Hotice)
Minesweeper game
 
Hi all, Right now, im working my final project for a class. We're supposed to be recreating the game "Minesweeper" I'm still in the early stages of productio...
[1 reply] : a really basic suggestion could be to replace false and true with 1 an... (by feedmetotheforest)
by Jarr10
Help
 
Why doesn't C++ allow the passing of complex, compound and compound/complex data types by value?
[2 replies] Last: By complex do you mean this? http://cplusplus.com/reference/std/com... (by king214)
Tetris Pieces
 
I'm working on doing a tetris game and i started to prototype everything but the problem i'm having is with the pieces. I have a 10x10 array defined for the ...
[7 replies] Last: Hanst99, i need to make one thing clear. Your seem like you know what ... (by LovestoCpp)
by Jarr10
Function Prototype help
 
I need help with this. A function named "sierra" that takes an integer and a boolean and returns a boolean.
[1 reply] : bool sierra( int i, bool b ) { return true; } http://www.cplusp... (by Lynx876)
How to reprint food WITHIN the borders in Snake..
 
If you visit this forum daily, you would notice that I have been posting topics about the snake game recently. I've been able to move the snake already and now,...
[3 replies] Last: By the way... Line 32 is wrong. if (snakeX == food_x && snakeY == ... (by Lynx876)
Help with strings
 
I need to split my string into 3 separate strings.For some reason only a few of my strings do what I want but the rest don't. Can some one help me? Thanks in ad...
[6 replies] Last: No prob. It just took me the best part of an hour to figure it out, ah... (by Lynx876)
Can someone PLEASE help me
 
Hello, I'm having a problem with this code I wrote. I'm supposed to enter a 8 character password, 5 letters and 3 numbers. If the password does not have 5 lette...
[3 replies] Last: lol, np. Looking at it now, I too would have put 8 in there... Never r... (by Lynx876)
December 2011 Pages: 1... 2728293031... 47
  Archived months: [nov2011] [jan2012]

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