s = input() t= input() D = {'s' : "shrinebell", 'b' : "beachball", "w" : "watermelon"} key = "sbw" for c in key : if c != s[0] and c != t[0] : print(D[c])