{{category Python}} !!!Pythonでテキスト処理 {{outline}} ---- !!テキストファイルを開く +ファイルをopenで開いてから +readで読み込む +読み終わったら、closeで閉じる f = open('ファイル名') data = f.read() f.close() *文字コードの指定オプション encoding='UTF-8'