checkers pattern by tabasa

a,b=gets.split(' ').map{|i|i.to_i}\x0d
o=u=1\x0d
a.times{\x0d
o=u\x0d
t=[]\x0d
b.times{\x0d
t<<o.to_s\x0d
o=-o+1\x0d
}\x0d
puts t*" "\x0d
u=-u+1\x0d
}

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page