Long Division FIXED by MeWhenI

puts (e=" ")*5+(b=(a=gets[0..-3])[0..0])*~-z=a.size,"  "+"_"*-~-~z,"9 | "+a,(4...z+=3).map{|n|e*n+a[0..1]+$/+" "*(n-2)+"- #{"%2d"%(b.to_i*9)}\n"+e*n+"__"},e*z+b

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

To protect the system from spam, please input your favorite sport (hint: I believe its name must start with 'g', case insensitive)

download

return to the top page