while True:
try:
short_str = input()
long_str = input()
for t in short_str:
if long_str.count(t)==0:
print("false")
break
else:
print("true")
except:
break