It's -1, but in theory could be something else on some exotic platforms, but still negative. See the related links below for further information.
Chat with our AI personalities
There is no ascii value for EOF. The constant EOF is a special value, not representing any character, but indicating an eof-of-file or error condition when using stream I/O. On the other hand, there is an ascii charactor end-of-file, <CTRL>Z, 26, or 0x1A which, in the DOS era, indicated the end of file in a text file, but this is not the same as the run-time library constant EOF.
Random example: while ((c= getchar()) != EOF) putchar (c);
In C++ EOF is a special function which will return nonzero when there is no more data to be read. In C++ nonzero means true, the alternative to nonzero is zero which means false.
Of course we do, 'FILE' and 'EOF' for example are all capitals.
Ctrl+Z mean EOF in WinDos, no matter what programming language you are using.