ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi I am a new member , I have problem about compiler.
When I execute my code , it is seen for only one second and I couldn't see the results.What Can I do for this stupid problem?
1-I am using C++ and Dev-C++ , actually the output of any code appears only for a second when it is executed , in a blink of an eye it dissappears.
Hi,
I think the problem u r facing is because u might have not added the getch() to the end of your program in c hopefully, so it just displays the o/p and the control returns immideatly.
hehe yea sounds like your running it in windows. Dos box comes up and then disapears again. This is normal.
You can disable this by right clicking on your app and then unchecking exit on program termination or something like that. Sorry havent written anything that runs in dos in a while now.
Hi I am a new member , I have problem about compiler.
When I execute my code , it is seen for only one second and I couldn't see the results.What Can I do for this stupid problem?
1-I am using C++ and Dev-C++ , actually the output of any code appears only for a second when it is executed , in a blink of an eye it dissappears.
there are solutions like running it in DOS (whatever), viewing user screen, or just ask for a variable in the end of the code or something :
int i=0;
readln i; (scanf (%d,i)); whatever.
As far as I remember you can use system (pause); or getchar(). Sometimes getchar() is cought by the last read function so maybe try to put two of them. getchar (); getchar ();
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.