def encounter(stest,ytest):
red = []
Stests = []
Ytests = []
for line in stest.splitlines():
if not line.isspace() and line != "":
Stests.append(line)
for line in ytest.splitlines():
if not line.isspace() and line != "":
Ytests.append(line)
smax = len(Stests)
ymax = len(Ytests)
for step in range(max(smax,ymax)):
try:
sworld = Stests[step].split
except:
sworld.append("")
try:
yworld = Ytests[step].split
except:
yworld.append("")
if sworld != yworld:
red.append((step),sworld[step],yworld[step])
print(red)
encounter("red demons dragon","star dust dragon")