f.readline example 1

This commit is contained in:
Mert Gör ☭ 2023-08-24 12:05:21 +03:00
parent f6adb94839
commit ba439fc907
No known key found for this signature in database
GPG Key ID: 2100A876D55B39B9
1 changed files with 6 additions and 0 deletions

View File

@ -0,0 +1,6 @@
with open('sample.py', 'r') as f:
while True:
s = f.readline()
if s == '':
break
print(s, end='')