c = ["abcdefghijklmnopqrstuvwxyz".chars, gets.chomp.chars].transpose.filter{|x| x[0] != x[1]}[0] puts c[0]+"to"+c[1]