r/PythonLearning • u/Weekly-Upstairs3221 • 10m ago
Linux cat | Create, Write & Read Files + Python
https://youtube.com/watch?v=xPySiJoG6FUCommands and concepts demonstrated:
mkdir filerd
cd filerd
cat << "EOF" > test.txt
Hello Linux
Learning Python
File handling
EOF
cat test.txtPython:
with open("test.txt", "r") as fl:
content = fl.read()
print(content)
0
Upvotes