14 lines
325 B
Python
14 lines
325 B
Python
![]() |
import re
|
||
|
import sys
|
||
|
|
||
|
|
||
|
def line_contains(line):
|
||
|
return re.match("(^(Mt ([1-9]|[1][0-9]|[2][0-8])))?(^(Mk ([1-9]|[1][0-6])))?(^(Łk ([1-9]|[1][0-9]|[2][0-4])))?(^(J ([1-9]|[1][0-9]|[2][0-2])))?(\, [1-9]?[0-9])", line)
|
||
|
|
||
|
|
||
|
for line in sys.stdin:
|
||
|
if line_contains(line):
|
||
|
print("yes")
|
||
|
else:
|
||
|
print("no")
|