e=1e10.to_i a,b=gets.split.map &:to_i x=a y=b loop{c=a/e;a%=e d=b/e;b%=e c!=d&&(puts (c*d==28)?(c