2000-07-01から1日間の記事一覧

ファイルをオープンする

f = open('test.txt') # ファイルをオープン f.close # ファイルを閉じる # open('test.txt','w') # 書き込みモードでファイルをオープン open('test.txt') {|f| } # ファイルは自動で閉じられる begin f = open('test_.txt') f.close rescue => err if err.…

備忘録目次 - ロバの耳