0

after i give the input
the screen disappears
all the commands are correct
even then it only takes input
how i can see outputs??

5
Contributors
4
Replies
6
Views
10 Years
Discussion Span
Last Post by WaltP
0

Use you command promt and run. Or if you want to run it directly add std::cin.get() at the end of main() to wait for a keystroke. However this wont work under certain circumstances as mentioned here.

0

>how to display result in C

Hi you can use
int main()
{
int x=1;
printf( "% d ", x );
getchar(); /*or you can use system("pause");*/
}

0

Use you command promt and run. Or if you want to run it directly add std::cin.get() at the end of main() to wait for a keystroke. However this wont work under certain circumstances as mentioned here.

Actually, wait for an ENTER :icon_wink:

Was that first post meant to be a Haiku or something ;)

More like a non-rhyming limerick -- 5 lines :)

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.