Constructor + main
IOException handling + closeFile()