www.digitalmars.com         C & C++   DMDScript  

c++ - new to C++, simple question

reply asdf <asdf_member pathlink.com> writes:
How can I make the Hello world program stay on the screen, rather that just
flash and disappear?

thanks
Apr 25 2004
parent reply David Harmon <<source netcom.com>> writes:
On Mon, 26 Apr 2004 02:11:11 +0000 (UTC) in c++,
asdf <asdf_member pathlink.com> wrote:

How can I make the Hello world program stay on the screen, rather that just
flash and disappear?

Run it from the command line.
Apr 26 2004
parent reply asdf <asdf_member pathlink.com> writes:
In article <408dba2c.365749518 news.digitalmars.com>, David Harmon < says...
On Mon, 26 Apr 2004 02:11:11 +0000 (UTC) in c++,
asdf <asdf_member pathlink.com> wrote:

How can I make the Hello world program stay on the screen, rather that just
flash and disappear?

Run it from the command line.

Apr 26 2004
parent reply Arjan Knepper <arjan ask.me> writes:
asdf wrote:
 In article <408dba2c.365749518 news.digitalmars.com>, David Harmon < says...
 
On Mon, 26 Apr 2004 02:11:11 +0000 (UTC) in c++,
asdf <asdf_member pathlink.com> wrote:


How can I make the Hello world program stay on the screen, rather that just
flash and disappear?

Run it from the command line.

where is the command line?

Windows NT/2000/XP => click 'start' -> 'Run' type cmd.exe in the 'open' box hit the 'ok' button Window 9X/ME => click 'start' -> 'Run' type 'command.com' in the 'open' box hit enter. Or search the startmenu for MS-DOS prompt(win98) or Command Prompt (win NT/2000/XP)
Apr 26 2004
parent reply asdf <asdf_member pathlink.com> writes:
In article <c6kvmf$867$1 digitaldaemon.com>, Arjan Knepper says...
asdf wrote:
 In article <408dba2c.365749518 news.digitalmars.com>, David Harmon < says...
 
On Mon, 26 Apr 2004 02:11:11 +0000 (UTC) in c++,
asdf <asdf_member pathlink.com> wrote:


How can I make the Hello world program stay on the screen, rather that just
flash and disappear?

Run it from the command line.

where is the command line?

Windows NT/2000/XP => click 'start' -> 'Run' type cmd.exe in the 'open' box hit the 'ok' button Window 9X/ME => click 'start' -> 'Run' type 'command.com' in the 'open' box hit enter. Or search the startmenu for MS-DOS prompt(win98) or Command Prompt (win NT/2000/XP)

what do I type in the command line? how can I make it not flash on the screen without running it from the command line?
Apr 29 2004
parent reply "Nico Heiligers" <nheiligers chello.nl> writes:
"asdf" <asdf_member pathlink.com> schreef in bericht
news:c6sbk7$apt$1 digitaldaemon.com...
 In article <c6kvmf$867$1 digitaldaemon.com>, Arjan Knepper says...
asdf wrote:
 In article <408dba2c.365749518 news.digitalmars.com>, David Harmon <



On Mon, 26 Apr 2004 02:11:11 +0000 (UTC) in c++,
asdf <asdf_member pathlink.com> wrote:


How can I make the Hello world program stay on the screen, rather that





flash and disappear?

Run it from the command line.

where is the command line?

Windows NT/2000/XP => click 'start' -> 'Run' type cmd.exe in the 'open' box hit the 'ok' button Window 9X/ME => click 'start' -> 'Run' type 'command.com' in the 'open' box hit enter. Or search the startmenu for MS-DOS prompt(win98) or Command Prompt (win NT/2000/XP)

what do I type in the command line? how can I make it not flash on the screen without running it from the

 line?

Just put in the following line just before the return statement from main. char pause = getchar();
Apr 30 2004
parent "N" <n n.n> writes:
in the botom where u have completed all the operations to be performed by
the program type

getch();

this function will pause the screen until u input something form the
keyboard ..... u can use it at any location where u want to pause the screen
for example if u want to pause before the hello word being displayed put it
before that statemebt ....... u can put it as many times as u wish as
aprogram statement . hope this would work for u

N
"Nico Heiligers" <nheiligers chello.nl> wrote in message
news:c6ucv8$jh5$1 digitaldaemon.com...
 "asdf" <asdf_member pathlink.com> schreef in bericht
 news:c6sbk7$apt$1 digitaldaemon.com...
 In article <c6kvmf$867$1 digitaldaemon.com>, Arjan Knepper says...
asdf wrote:
 In article <408dba2c.365749518 news.digitalmars.com>, David Harmon <



On Mon, 26 Apr 2004 02:11:11 +0000 (UTC) in c++,
asdf <asdf_member pathlink.com> wrote:


How can I make the Hello world program stay on the screen, rather






 just
flash and disappear?

Run it from the command line.

where is the command line?

Windows NT/2000/XP => click 'start' -> 'Run' type cmd.exe in the 'open' box hit the 'ok' button Window 9X/ME => click 'start' -> 'Run' type 'command.com' in the 'open' box hit enter. Or search the startmenu for MS-DOS prompt(win98) or Command Prompt (win NT/2000/XP)

what do I type in the command line? how can I make it not flash on the screen without running it from the

 line?

Just put in the following line just before the return statement from main. char pause = getchar();

Aug 24 2004