scanf
returns the number of items actually readgetchar
returns EOF
'E' |
'C' |
'E' |
' ' |
'2' |
'0' |
'9' |
'\n' |
getchar()
returns EOF
EOF
is not an ASCII value
getchar()
returns an int
int inCh ; while ((inCh=getchar()) && inCh != '\n' && inCh != EOF) { }
gets()
and sscanf()
scanf
returns the numbers of items matched or assigned
EOF
if end-of-file before a matching success or failurescanf()
if (scanf("%d", &x) != 1) ....
myProg < testin.txt
myProg > testout.txt
EOT
, end of tranmission