Beginners - March 2015 (Page 8)

Using a do-while loop to validate input
 
I'm having trouble with this program. It produces the correct sample output given to me by my professor, but apparently it must not work all the time because wh...
[15 replies] Last: It finally worked! Thanks a lot to both of you for all your help. (by steezedq)
by brenny
How C++ works differently in OSX and Windows
 
Hello, I've experimented with a little python, and some swift. I didn't really enjoy what I was learning with these and moved on to C++. I am currently learn...
[1 reply] : The difference is not in the C++. Every application has to use the fa... (by keskiverto)
Copy constructor in derived class
 
let's say if i have 2 classes like: class base{ private: int age; string name; string *namePtr; public: ...
[8 replies] Last: what if the base class doesn't have a user defined copy constructor ?... (by keskiverto)
How to initialize Array in Constructor and access elements using an object
 
What is the proper syntax for accessing an array within a constructor and passing the argument into a function? class Polynomial{ public: in...
[2 replies] Last: Thank you so much! (by vkhanhvy)
how to use cin in a if statement
 
How do I use a if statement with cin like, if the user types ok then this would happen? I only know how to use cin and if statements if the user inputs integers...
[1 reply] : #include <iostream> #include<string> int main() { std::string ch... (by MiiNiPaa)
I'm confused about this user defined data type.
 
What exactly does this do? So far I understand that it is defining a structure type as type, but I'm getting confused about what myStruct does or is. ...
[2 replies] Last: myStruct is a synonym for struct type Line 6 is effectively: ... (by AbstractionAnon)
Troubles with setprecision
 
I'm trying to make a loan calculation program for my class and I'm having trouble with getting my output to have ONLY two decimal places. I'm getting really wei...
[2 replies] Last: Thank you! Problem solved. (by KyuubiCalvary)
by GilTea
Import file reading extra line
 
Write your question here. Hi, I have built a program that imports and reads a file but I am having a small problem with my code. When the file is reading the...
[1 reply] : Because of this !import.eof() . Do not loop on eof (unless you know h... (by MiiNiPaa)
Help me with Array please!
 
When I run my program, everything runs fine until I get to the findHighest(rainfallArray, numMonths, highestMonth); in line 57. For some reason, after cout tota...
[2 replies] Last: oh yes yes. thank you. that was a silly mistake. i thought for a secon... (by toesockshoe)
Recursive function with no parameters
 
Hello everyone. Is here anyone who can explain to me what a recursive function with no parameters is??? I must write a function that will count the sum of ar...
[17 replies] Last: i agree with keskiverto. you learn by coding yourself. however i am n... (by anup30)
What interesting things can I make using C++?
 
I have been learning C++ for 8-9 months. But actually I am not being happy with it. I can't feel the happiness of creating useful and interesting programs using...
[12 replies] Last: TarikNeaj wrote: SDL is more c-ey well, SDL won't use classes ... (by anup30)
while loop problem
 
Q)Write a C++ program that takes a positive integer from user and store it in variable posNumber. Follow these conditions; If the number is less than 1, print w...
[4 replies] Last: Thanks that worked :) (by b3ginn3r)
by HG319
Using a stack to compare letters in a string
 
So I have to write a code and must you a stack, to determine if the sequence is is in the form of X^nY^n.
[1 reply] : I am not sure what is wrong with your code, it seems unnecessarily com... (by fg109)
Is this set up correctly?
 
Could somebody just tell me if I have my vector set up in my class correctly? // WorkerBee.cpp #include "WorkerBee.h" #include "Vector.h" #include...
[1 reply] : The members size and currentWord have no purpose. Client code has no r... (by keskiverto)
helpppppppppppppppppppp....function
 
i m doin this code......here shows all the even numbers from random nubers bt i want to find first 3 even nuber....any solution? #include<iostream> #include<...
[6 replies] Last: txxx a lot (by rahul820)
String Length Error
 
Hi, I'm trying to find the length of a string, my program runs fine but always tell the length 0 .. In the condition of for loop if I write Mystr !='\0' th...
[4 replies] Last: Thanks Buddy.. @Peter87 I've tried the same program on eclipse latest ... (by ButchCavendish)
HELP End of File
 
I'm completely baffled as to why my code refuses to read the last line in the "Numbers.txt file. Looks like this: Copies Sold Selling Price 4360 35....
[4 replies] Last: YES!!!!! That worked. Both of you were correct. THANKS SO MUCH! (by sfisher1987)
How do I make a simple web crawler using C++?
 
I want to make a simple web crawler using C++. Can a web crawler be made with C++? If yes, then what are the procedures to make one?
[1 reply] : Try reading this - http://stackoverflow.com/questions/4278024/a-very-s... (by TarikNeaj)
by haffez
file handling
 
In c++ we could easily read and and write data from txt file format,i am trying to develop a program in c++ that read and write data form doc format files, i se...
[no replies]
Help with problem
 
Hi I'm actually a working on a Networking degree but one of my electives is a C++ class. I have a problem I need to make sure I use vectors not static Arrays. I...
[6 replies] Last: Hello again. Since it seems you have been trying i made a code for you... (by It3rat0r)
March 2015 Pages: 1... 678910... 51
  Archived months: [feb2015] [apr2015]

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