A,B,C=$<.map &:to_i puts Rational(A*B*C,[(C-A).abs,C+A].product([(C-B).abs,C+B]).map{|x,y|(x*B).gcd y*A}.max)