+ 6
Can someone help me ? Please 😐
Can I use for loops to get a word from a text like : file called "hello.txt" ( just writes hello or hey there 😑 ) can i find a word in it's text and edit it using for loops like for "hello" in "hello.txt": print("hey there")
2 ответов
+ 6
@Carlos Andrés Hidalgo Martí but how I tried to use the readlines with for loops like for "hello" in file.readlines
+ 1
Of course, you should review the file writing and reading part of the python course, there it is.