Hi everyone,
This is my first post on this forum & I hope to hang around for a long time. I have started learning C as hobbyist. CPL by Kernighan & Ritchie is my main book and Google a sidekick .
In one of the exercise in the book the value of EOF is asked to be printed. I used two methods:
and#include <stdio.h>
main()
{
printf("The value of EOF is %d\n\n", EOF);
}
The output I get are different in both the cases. Why is that so?#include <stdio.h>
main()
{
putchar (EOF);
}