|
General Details
|
|
C++
|
|
Posted 300 Days Ago
|
|
224 Views
|
|
Received 4 Ratings
|
|
Age machine
Description
It takes your user imput (age) and doubles it with a simple math algorithim.
Technical
DEV c++ BETA, small program.
Source Code
Comments
| Please login to post comments. |
|
|
Ok, i was getting things like that rom sirtom93, it was just something i tried..
|
|
|
Try to avoid using System("PAUSE"); to pause your program. That function calls something in the windows library, so it renders your program useless on something like Linux. It's good to get into the habit of writing code that's cross-platform.
A better alternative would be:
cin.ignore();
cin.get();
The cin.ignore() line is optional. It just clears the buffer in case you had some characters left over. In most cases you can leave it out, but if the program still doesn't pause, just add that in.
|
|
|
I wrote this myself, trying to learn C++, the basic structure is from Cplusplus.com, although, this one was wtritten entirly by me.
|
More "C++" Source Codes By This Author
Recently Posted "C++" Source Codes
Recently Rated "C++" Source Codes
|