20 lines
273 B
Python
20 lines
273 B
Python
import re
|
|
import sys
|
|
|
|
def check(a):
|
|
pattern = r'^(?!10$)10*$'
|
|
|
|
if re.match(pattern, a):
|
|
return True
|
|
else:
|
|
return False
|
|
|
|
|
|
|
|
for line in sys.stdin:
|
|
word = line.strip()
|
|
if check(word):
|
|
print("yes")
|
|
else:
|
|
print("no")
|