a,l,$,=:+,:<,' '
puts [6484,a,0,1,3,l,2,3,3].join
[0,1].map{|x|puts [a,x,3,x].join
30.times{|t|v=x+4;u=x*60+9+t;puts [a,v,v,v,a,v,3,6,*[a,6,6,6]*(29-t),l,6,x,u,a,v,u,v]}}
60.times{|t|puts [a,2,2,2]+(0...t).map{|s|[a,8+t-s,69+s,5,l,3,5,6,a,2,6,2]}}