ab = list(map(int,input().split())) print([":-)",":-("][sum([ab[i]**ab[i+1] for i in [0,2,4]])%2])