def ascan; gets.split.map(&:to_i); end A,B = ascan if A == 0 || B == 0 p 0 else as = A.abs.to_s bs = B.abs.to_s az = as[1..-1] bz = bs[1..-1] if az=~/^0+$/ && az.size >= 2 && bz=~/^0+$/ && bz.size >= 2 p A*B/10 else if (A*B).to_s.size > 8 puts "E" else p A*B end end end