diff --git a/TaskA03/task3.py b/TaskA03/task3.py new file mode 100644 index 0000000..c94bc88 --- /dev/null +++ b/TaskA03/task3.py @@ -0,0 +1,10 @@ +with open("simple.in", encoding="utf-8") as f: + lines = f.readlines() + for line in lines: + line = line.strip() + line = line.split() + for i in range(len(line)-1): + if line[i][:2] == "19": + if 0 < int(line[i][3:4]) < 99: + if line[i+1][:2] == "r.": + print(" ".join(line)) \ No newline at end of file