Created
June 3, 2022 23:20
-
-
Save kozo496/7ef084653dd2c02cb5a053eada167e4a to your computer and use it in GitHub Desktop.
textファイルを読み込んで、行ごとのリストにする。
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# `test.txt`ファイルから一行ずつ読み込む | |
with open('test.txt', 'r) as f: | |
lines = [line.rstrip() for line in f] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment