Help a n00b

  • Thread starter JamesU
  • Start date
JamesU
Gold Member
732
3

Main Question or Discussion Point

Every time I compile and run a program in Dev-C++ Command prompt only opens for less than a second and closes immediately. can anyone help?
 

Answers and Replies

dduardo
Staff Emeritus
1,894
3
START->RUN

Type: cmd (assuming your on windows xp)
Type: cd <directory where program is located>
Type: <program name>
 
644
1
Use getch() ?
Code:
#include<stdio.h>
#include<conio.h>
int main()
{
    printf("Hello World");
    getch();
    return 0;
}
-- AI
 
Programs run until they get to the end of the code, use getchar()
 

Related Threads for: Help a n00b

Replies
1
Views
3K
Top