local mfl, mce = math.floor, math.ceil
local n = io.read("*n")
local t = {}
local mul = 1
while 0 < n do
  if n % 2 == 1 then
    table.insert(t, mul)
  end
  n = mfl(n / 2)
  mul = mul * 2
end
if #t == 1 then
  print("-1 -1 -1")
else
  local a = t[1]
  local b = a
  local c = 0
  for i = 2, #t do
    b = b + t[i]
    c = c + t[i]
  end
  print(a .. " " .. b .. " " .. c)
end