n = int(input()) L = [int(s) for s in list(bin(n)[2:])] a,b,c = 0,0,0 if sum(L) < 1: a,b,c = -1,-1,-1 print(a,b,c) else: t = 2 for i in range(-1,-len(L)-1,-1): if L[i] > 0 and t == 2: t -= 1 a += 1 << (-1-i) b += 1 << (-1-i) elif L[i] > 0 and t == 1: t -= 1 a += 1 << (-1-i) c += 1 << (-1-i) elif L[i] > 0 and t == 0: a += 1 << (-1-i) b += 1 << (-1-i) print(a,b,c)