ans = set(["watermelon", "beachball", "shrinebell"]) s = input() t = input() ans.remove(s) ans.remove(t) for ss in ans: print(ss)