ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1094. E-screen

Input problem
Posted by BoRN 8 Oct 2002 22:54
I don't know when the input will terminate any one pls help??
Re: Input problem
Posted by nullman 9 Oct 2002 01:37
while ((c=getc(stdin)!=-1) /* while not EOF*/
  switch (c)
  {
    case '>' :
    case '<' :
    .....
  }
....

may be something of this sort.
c=getc(stdin)!=-1[>> what does -1 refer
Posted by BoRN 9 Oct 2002 19:07
Re: c=getc(stdin)!=-1[>> what does -1 refer
Posted by Knot Skycreeper[th] 10 Oct 2002 21:18
i think it's End Of File (EOF)

because input to standard input is a file.
so... mah!!!