diff --git a/TaskA01/task1.py b/TaskA01/task1.py new file mode 100644 index 0000000..59cf72b --- /dev/null +++ b/TaskA01/task1.py @@ -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 +