The
printf method prints the provided string onto the standard output (typically the screen).
The
getchar() method retrieves a character from the standard input (typically your keyboard).
The
EOF stands for End Of File.
So this program prints "Enter character(CONTROL-Z to end):" on the screen.
It then retrieves a character entered by the user.
If the character entered by the user is Not equal to EOF, it prints "End of file not encountered!" on the screen.
Please try running the application to see the output.
Use a debugger to step through the application to understand what is happening.
And use resources, like Google, to research the topic before asking your question.
-Frinny