Beginners - March 2013 (Page 23)

Problem with loop and reading input file
 
I am writing a program for an assignment, and we have to read in a .csv file that contains information about various chemicals and store that information in Che...
[6 replies] Last: Yea, I can't figure out what the problem is. I connected to my school'... (by dcast55)
by apa125
2D dynamic array problem
 
Hi guys, I am new to C++ and I am having trouble to write a function that return an array by summing up the element of each row from a 2D array .here is the co...
[3 replies] Last: thanks a lot (by apa125)
What is data driven programming?
 
I have been set an assignment which suggest the use of data driven programming and I'm struggling to understand the difference between this and a standard codin...
[4 replies] Last: Thanks fr the help guys- and both replies from Abstraction and Lowest ... (by Anonagon)
NEED HELP PLEASE
 
i need help converting this code into functions #include <iostream> #include <string> using namespace std; int main() { // declare variables bo...
[4 replies] Last: this is what i have now. why does it have so many errors? what did i ... (by Beginner007)
Function to write to specified file name
 
Hi everyone, I'm trying to write a function that will write to a filename specified in the main function. The function should take the name argument as a con...
[5 replies] Last: string s = "my file.txt"; fstream inout; inout.open(s.c_str(), ios::ou... (by IWishIKnew)
Understanding Class Interaction (Collaboration)
 
I downloaded code from MSDN that generates a window. The window is a class which includes all the information about it and the main message loop. In this wind...
[1 reply] : bumping as it went off the first page. (by Bugsplatter)
Jumping to the main function
 
In this program I am trying to go from one of the void functions, back to the main function. But every time I try to compile it I get the error: "'main' was no...
[6 replies] Last: Or better: Forget forever those goto keyword of C++! (by tcs)
Overloading extraction operator
 
Is there a reason why I can't reach my extraction for the istringstream stuff? It keeps looping before it even reaches the line : stuff >> year >> name >> perce...
[2 replies] Last: I think this has nothing to do with your question, but: 1. I don't un... (by tcs)
really need a help!!
 
sorry, i'm noob in programming and i really need a help. the question "There is an array of String type named arrFruits with the following values: pear, ban...
[1 reply] : #include <iostream> #include <algorithm> #include <vector> #include <... (by Facedown)
Purpose of Private and Public Access Specifiers, OOP??
 
Just a general question, relating to theory. I was just wondering, what exactly is the purpose of declaring private data members? What will be the dis-advantage...
[3 replies] Last: I don't know how this will match question you asked but i'll give exam... (by eraggo)
Purpose of Private and Public Access Specifiers, OOP??
 
Just a general question, relating to theory. I was just wondering, what exactly is the purpose of declaring private data members? What will be the dis-advantage...
[3 replies] Last: freddy explained very well, but I can add to it that it is more way of... (by Shinigami)
by Jace
Function issue
 
{ WIN32_FIND_DATA file; HANDLE search_handle=FindFirstFile(L"C:\\*",&file); //it says the L is incompatible if (search_handle) { do ...
[5 replies] Last: There are no red lines under anything, so it seems like there wouldn't... (by Jace)
associating a character name with a numerical number in an array
 
I have a range of data which includes a designation name of a herd of cows (char), a number of cows per herd(Double) and a range of paddocks to associate with t...
[2 replies] Last: Thanks for that solution MiiNiPa, Int would will be fine for these ele... (by wannaBgeek)
Help with functions and infiles!
 
I am a beginner in c++ programming and I was assigned a project to prompt the user for the name of a file. When inputted the output will be a directory containi...
[1 reply] : some of it may be sloppy but I really do not know what else to put in ... (by sojalife12)
HELP!
 
A restaurant has 3 lunch combos for customers to choose: Combo A: Fried chicken with coleslaw [price: 6.00] Combo B: Roast beef with mashed potato [price: 6.2...
[2 replies] Last: Thank you. I feel like an idiot. It works now. (by lavekyl)
by SRT04
printReverse names
 
Working on a project and I need to print names from an file in reverse order from Brown, James to James Brown. I have an idea on setting a void printReverese fu...
[1 reply] : Apart from the first line, the data seems to be: int 1 string ... (by Chervil)
by Tax
Arrays for beginners
 
Hi, I'm totally new here, trying to make first steps in programming. Could you check the code? It's rewritten from the book, but doesn't work :/ I'm using Win7...
[6 replies] Last: Isn't the 13th line initializer? Yes, but you initialize only the fi... (by maeriden)
Memory Leak help?
 
Hey guys I'm having an issue understanding a line of code: message = TTF_RenderText_Solid(font , vectorSize.str().c_str(), textColor); This line seems to...
[1 reply] : http://www.libsdl.org/projects/SDL_ttf/docs/SDL_ttf_43.html (by cire)
String manipulation code
 
Hey guys, I'm trying to take text from a file, save it into a string, then isolate letters only and save the word itself. example: input --> "hey," saves...
[6 replies] Last: @tntxtnt: You're correct, I remade it: for (std::string::iterator str... (by Lowest0ne)
Function works for only 201700 times?
 
Hi everyone, I've got another beginner question so I hope you can help me. In my code I have a struct called 'test', a function called 'add' to connect a te...
[14 replies] Last: Comparison of int, char and bitset. #include <iostream> #include <bit... (by Chervil)
March 2013 Pages: 1... 2122232425... 87
  Archived months: [feb2013] [apr2013]

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