puts 2.times.map{ gets.chomp }.all?{|s| s == s.to_i.to_s } ? :OK : :NG