When I execute the following piece of code I'm prompted to typed in some characters, however nothing happens when I press return. Surely a value should be returned indicating how many characters are contained in the input?
Code:#include <stdio.h> main() { long nc; nc = 0; while(getchar() != EOF) ++nc; printf("%ld\n", nc); }