# coding: utf-8 tea = list(map(int,input().split())) tapioka = (tea[0]**tea[1])+(tea[2]**tea[3])+(tea[4]**tea[5]) if tapioka % 2 == 0: print(":-)") else: print(":-(")