Hi James,

I don't know what's going wrong, but it did what you said it would do.
I ran it on a SparcServer 20.

For fun, I wrote this program:

#include <stdio.h>

int main ()
{
   int c;

   puts ("Type a character.");
   c = getchar (stdin);
   putchar (c);
}

When I ran a.out, it displayed "c", the character I typed, and then it
put the cursor about five columns to the right of the host name.  So
I backspaced, only to hear a beep.  But the cursor would move again
after I hit the "enter" key.  In your program, "c = getc (stdin)" kept
getting a "[".

I'm stumped.

Bill

Reply via email to