home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Microsoft Programmer's Library 1.3
/
Microsoft-Programers-Library-v1.3.iso
/
sampcode
/
qc_prog
/
chap05
/
if.c
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
NeXTSTEP
RISC OS/Acorn
UTF-8
Wrap
C/C++ Source or Header
|
1988-04-05
|
279 b
|
11 lines
/* if.c -- simple IF statement */
char ch;
main()
{
printf("Do you want to continue y/n? "); /* prompt */
if (ch = getche() == 'y')
printf("\nLet's continue ...\n"); /* if true */
printf("\nAll done.\n"); /* always executed */
}