Hi to all members,I just wrote my first java program, it compiles and runs and all, but the console window closes too quickly u can hardly see the output.How can i rectify that?
Printable View
Hi to all members,I just wrote my first java program, it compiles and runs and all, but the console window closes too quickly u can hardly see the output.How can i rectify that?
Get a better compiller. I use JCreator and it keeps any information up there for you to review.
Or, if you don't want to change, set it to ask for input at the end of the code (as a test, remove it later).
Use that and it will just sit there waiting for input, and not close.Code:Scanner input = new Scanner(System.in);
int askForInput = input.nextInt();
It's not a compiler, it's an IDE (Integrated Development Environment). The compiler is not relevant to this problem.Quote:
Originally Posted by omgwtfbbq9999
I may sound pedantic, but then I'm a programmer... :rolleyes:
The first step towards wisdom is calling things by their right names...
Chinese proverb