def most_char_count(char_arr)
  3 - char_arr.map{|char| char_arr.count(char)}.max
end

input = readlines
n = input[0].to_i
str_list = input[1..3].map(&:chomp)

puts (0...n).to_a.map{|i| most_char_count(str_list.map{|str| str[i]})}.inject(:+)
