Reading from a file There are various way to iterate over a file. Let's compare various variants. unbuffered Read() buffered Read() Scanner ReadString ReadBytes