program runs when i run through compiler & also when I run it from a DOS window.
But when I go to run the .exe from the Debug folder (is this where you generate the .exe btw), it opens DOS & closes right away.!
Pls help ASAP.. Thanks!
program runs when i run through compiler & also when I run it from a DOS window.
But when I go to run the .exe from the Debug folder (is this where you generate the .exe btw), it opens DOS & closes right away.!
Pls help ASAP.. Thanks!
There are 2 ways to fix it 1. you use Ms Dos Prompt or you can add this to your program you need to #include <stdlib.h> and just before the end of the program add system("PAUSE");
This'll pause the program.
Wave upon wave of demented avengers march cheerfully out of obscurity unto the dream.
you could also use the getch() fuction in conio.h as the last line of the code.