@ tnavid: I've pretty much given up on discouraging the use of the "system()" function, but if you're going to suggest it then you HAVE to remind people to include the cstdlib header file. Also, main must return an integer. That's part of the standard.
why main must return integer? as you see it's "void main"
"main" function like other functions can be anytype: int,void,..
but you are right about stdlib header.
The entry at the top of page 62 is what I was referring to.
An implementation shall not predefine the main function. This function shall not be overloaded. It shall
have a return type of type int, but otherwise its type is implementation-defined.
I've read in a lot of places that using system("pause"); isn't the best thing to do. I mean I'll give it a try and see if I can get it working but a lot of people suggest other methods.
I appreciate the replies though. I'll mess around with it. It's still not working. :p