Sha256: 5a7dfed512842ff3b8c864502c0281164a5151ba6c7a82a9c2b31e95c236ea56

Contents?: true

Size: 326 Bytes

Versions: 39

Compression:

Stored size: 326 Bytes

Contents

1つの文字列を受け取り、文字列と一致するファイル名のテキストデータを表示するプログラムを作成せよ。


- File.read

text = File.read(ファイル名)

File.readメソッドは、受け取ったファイル名と同じ名前のファイルのデータを読み込むメソッド。

Version data entries

39 entries across 24 versions & 1 rubygems

Version Path
ruby_learner-1.1.10 takahashi/sample_prog/question/9_1.org
ruby_learner-1.1.9 questions/sequential_check/section_9/part_1/lib/sentence.org
ruby_learner-1.1.9 takahashi/sample_prog/question/9_1.org
ruby_learner-1.1.8 questions/sequential_check/section_9/part_1/lib/sentence.org
ruby_learner-1.1.8 takahashi/sample_prog/question/9_1.org
ruby_learner-1.1.7 takahashi/sample_prog/question/9_1.org
ruby_learner-1.1.7 questions/sequential_check/section_9/part_1/lib/sentence.org
ruby_learner-1.1.6 takahashi/sample_prog/question/9_1.org
ruby_learner-1.1.6 questions/sequential_check/section_9/part_1/lib/sentence.org
ruby_learner-1.1.5 takahashi/sample_prog/question/9_1.org
ruby_learner-1.1.5 questions/sequential_check/section_9/part_1/lib/sentence.org
ruby_learner-1.1.4 takahashi/sample_prog/question/9_1.org
ruby_learner-1.1.4 questions/sequential_check/section_9/part_1/lib/sentence.org
ruby_learner-1.1.3 takahashi/sample_prog/question/9_1.org
ruby_learner-1.1.3 questions/sequential_check/section_9/part_1/lib/sentence.org
ruby_learner-1.1.2 questions/sequential_check/section_9/part_1/lib/sentence.org
ruby_learner-1.1.2 takahashi/sample_prog/question/9_1.org
ruby_learner-1.1.1 takahashi/sample_prog/question/9_1.org
ruby_learner-1.1.1 questions/sequential_check/section_9/part_1/lib/sentence.org