S = gets.to_i


x1 = 0
y1 = 0
x2 = 10E9
y2 = 1

x3 = 0
y3 = 0



if S == 10E18 then
    x3 = 0
    y3 = 10E9
    puts [x1,y1,x2,y2,x3,y3].join(" ")
elsif S >= 10E9 then
    x3 = S%10E9
    y3 = S/10E9
    puts [x1,y1,x2,y2,x3,y3].join(" ")
else
    x3 = S%10E9
    y3 = 0
    puts [x1,y1,x2,y2,x3,y3].join(" ")
end 