forked from miczar1/djfz-24_25
task1 done
This commit is contained in:
parent
6e757f969a
commit
35dfc38168
11
TaskA01/task1.py
Normal file
11
TaskA01/task1.py
Normal file
@ -0,0 +1,11 @@
|
||||
with open("shakespeare.in", encoding="utf8") as f:
|
||||
lines = f.readlines()
|
||||
for line in lines:
|
||||
line = line.strip()
|
||||
line = line.split()
|
||||
for word in line:
|
||||
if word[:6] == "Hamlet":
|
||||
result = " ".join(line)
|
||||
print(result)
|
||||
break
|
||||
|
Loading…
Reference in New Issue
Block a user