Computers can store information on a wide variety of hardware, such as magnetic disks, thumb drives, optical drives, and so on. To save programmers from having to write code that is specific to each storage device, operating systems present an abstraction called the file system . In turn, Kotlin provides us with the tools we need in order to be able to explore the files on a computer and read and write information. In this chapter, we will make use of some of these tools to read and write text files.
In this chapter, we ...