tapi = list(map(int, input().split())) cnt = 0 for i in range(0, 5, 2): cnt += tapi[i] ** tapi[i+1] if cnt % 2 == 0: print(":-)") else: print(":-(")