s1 = input() s2 = input() li = ["watermelon","beachball","shrinebell"] if s1 in li: if s2 in li: li.remove(s1) li.remove(s2) print(li[0])