Tuesday, July 28, 2009

How do I display the output of a C++ program in the Command Prompt?

I am also using Borland to create my program.

How do I display the output of a C++ program in the Command Prompt?
printf("output to display");





or you could use





cout %26lt;%26lt; "output to display";





or





putc( char_var, stdout);





or





puts( string_var);





See also:


http://www.cplusplus.com/doc/tutorial/


http://www.cprogramming.com/


No comments:

Post a Comment