WLJS LogoWLJS Notebook

EndOfFile

EndOfFile is a symbol returned by Read when it reaches the end of a file.

Examples

Read until end of file:

While[(line = Read[stream, String]) =!= EndOfFile, 
  Print[line]]

Check for end of file:

Read[stream] === EndOfFile

Please visit the official Wolfram Language Reference for more details.

On this page