Mail Archives: djgpp/1997/01/27/20:18:24
Can someone help me ?
In my program are two function - first is printf() and second is
getch(),
but - first is called getch() and then printf(). Ghosts in the GCC :-)?
All examples showed bellow running correctly in Borland C++ 3.1.
Thanks for all answers !
Marian (xlysak AT informatics DOT muni DOT cz)
example --->
void main()
{
int ch;
printf("Hi , ");
ch = getch();
}
Output is (!) :
(1) - wait for getch()
(2) - Hi ,
void main()
{
int ch;
printf("Hi , ");
ch = getch();
cprintf(" everybody.");
}
Output is (!) :
(1) - wait for getch()
(2) - everybody.Hi ,
void main()
{
int ch;
printf("Hi , ");
ch = getch();
printf(" everybody.");
}
Output is (!) :
(1) - wait for getch()
(2) - Hi , everybody.
void main()
{
int ch;
cprintf("Hi , ");
ch = getch();
cprintf(" everybody.");
}
Output is (OK) :
(1) - Hi ,
(2) - wait for getch()
(3) - everybody.
- Raw text -