General C++ Programming - March 2013 (Page 40)

Recursion?
 
I am trying to write a section of a program that generates names of 3 letters. First letter a capitol consonant, a second letter that is a vowel, the third that...
[6 replies] Last: EDIT: Nvm I figured it out. (by oudavid1)
by abrupt
Simple Formula For C++
 
Why am I getting these random long numbers as a result? Month: March, 2013 ---------------------------------- Total Collected: $ 63924.62 Sales: ...
[1 reply] : Where have you declared and initialized total_collected? please post t... (by abhishekm71)
Keyboard Input On Specified Port
 
Basically what I am trying to do is have 6 external num-pads that all act independently that will be input devices for a FRC (FIRST Robotics Competition) scouti...
[no replies]
by ostar2
expected primary-expression before '=' token
 
decide.h|5|error: expected primary-expression before '=' token| That is the error I get when trying to compile. I have worked on it for hours and still could n...
[4 replies] Last: also this function is a little ridiculous. Same effect: bool decid... (by Disch)
How make cin accept different punctuation from vector
 
Question is a bit odd, didn't know how to word it. My program is a dictionary vector with a cin at the end that will read your input and check if it's in the d...
[1 reply] : maybe it's your function translate_to_lower however check this cod... (by joneele)
Input data from file/write data to file
 
Any help with this would be appreciated. I can't figure much of it out. The parts I have are written in a comment. Ben has been administering a MBTI perso...
[2 replies] Last: I'm starting to feel that way! It has me completely confused. Any help... (by madeinsilence)
Help with copying one file to another file I/O help please!
 
I'm having some trouble with copying one I/O stream into another. I've put the first one into an array but I cannot get my second prompt to copy the .txt file t...
[1 reply] : This code does as follows: 1. Reads in two file names (lines 18-22). ... (by tcs)
by abrupt
File I/O
 
I am trying to write a program for class that reads from an input file the month, year & total collected. I am using notepad for the input file. This is wha...
[2 replies] Last: 1. Line 26: infile >> month; is only accessed if infile is false. It... (by Krahl)
Cannot type in CMD
 
I recently came across the issue of not being able to type in my cmd console. I was working on a project in MSV; while starting a new one I was unable to type i...
[10 replies] Last: Yeah. Sorry about not presenting the full code. I asked my friend wh... (by WillDesigned)
by Cnaoum
NEED HELP; the days of our lives
 
Hi, need help! no idea how to do this kind of program. Any help will be appreciated! Your program should take the user’s birthday and allow the user to ...
[1 reply] : What are you stuck on? This is pretty clear cut. (by ResidentBiscuit)
Initializer lists vs initializing in function
 
I am just curious as to what is more "modern" IE C++11 common coding practices What would be more appropriate Node::Node(void):m_Data(0), m_Pnext(NULL), ...
[4 replies] Last: Thanks a lot man! (by DrolArumil)
by serjo
Converting char pointer to string
 
Here's the code I'm working on: string* arrayPush(string *array, char **toks){ if(array[sizeofHistory -1].empty()){ //find the next ava...
[10 replies] Last: array = new string(*toks); see: http://www.cplusplus.com/reference... (by tcs)
help with reading from a file
 
Hey, I am making a game in c++ and I have made it so that it uses an ofstream to save your people to a text file in this format Cassandra 6 10 7 8 1 40 20 0 ...
[2 replies] Last: Thanks for the help, I got it to now read line by line, and it can fin... (by Melinyel)
by xsesx
Missing something obvious as always...
 
My code won't run properly. The error says unresolved externals. Any advice? #include <iostream> #include <cstring> using namespace std; char again; ...
[2 replies] Last: @DTSCode: No, `again´ shouldn't be declared `extern´! @xsesx: Pleas... (by tcs)
Looping & Calculate the percentage
 
#include <iostream> #include <iomanip> #include <math.h> using namespace std; int main() { const int membership_Fee = 2500; double rate = 0.04; con...
[1 reply] : i have done the loop for years. (by fumes007)
by serjo
dup2() redirect
 
I am a bit confused about dup2. I am trying to redirect stdout to file and back. It works with a fork(). I'm having trouble making it work without forking. Cl...
[2 replies] Last: I think your problem arises from mixing stdio routines with basic oper... (by tcs)
How do I compile a library in windows?
 
I have download the SOIL library http://www.lonesock.net/soil.html for loading textures in OpenGL, however it doesn't come with a SOIL.lib file but a file ca...
[11 replies] Last: Struggled around with it for a while but I got everything just working... (by closed account 2NywAqkS)
Tic-Tac-Toe
 
I need to create a program for this, but I don't even know where to start with it. Any help would be appreciated. Tic-tac-toe, originally called noughts and ...
[no replies]
Binary file (EOF)
 
I'm reading a binary file and I want to read all of the letters, but I have noticed that it dosen't read all of the letters and I think it is because eof apears...
[11 replies] Last: Compare it to mine, see if you have everything in yours what this has.... (by TheBeardedQuack)
Struct and pointers. Pointer passed into a function looses the adress it points to
 
Greetings. sem is a pointer to semantic which is a struct type variabl. I pass the sem into function yylex so i can fill the semantic.i and semantic.s(s point...
[2 replies] Last: thank you very much this was really helpfull..i found too the first an... (by monkey90)
March 2013 Pages: 1... 3839404142... 51
  Archived months: [feb2013] [apr2013]

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