getchar() wont read from an array of chars, it reads from the standard input device, one character at a time.
You're right, -1 and \n are each 2 characters, so you can't do a single character...
Type: Posts; User: anduril462
getchar() wont read from an array of chars, it reads from the standard input device, one character at a time.
You're right, -1 and \n are each 2 characters, so you can't do a single character...