LessonAbout 6 minLesson languageEnglishதமிழ் (Tamil)हिन्दी (Hindi)മലയാളം (Malayalam)తెలుగు (Telugu)ಕನ್ನಡ (Kannada)বাংলা (Bengali)मराठी (Marathi)ગુજરાતી (Gujarati)ਪੰਜਾਬੀ (Punjabi)Chapter 12 · Lesson 1 of 501. Open and read a fileVariables are forgotten when a program ends; files stay. Open a text file, read all of it with read(), and close it.