import std.algorithm;
import std.array;
import std.conv;
import std.math;
import std.range;
import std.stdio;
import std.string;
import std.typecons;

T read(T)() { return readln.chomp.to!T; }
T[] reads(T)() { return readln.split.to!(T[]); }
alias readint = read!int;
alias readints = reads!int;

int calc(string a, string b, string c) {
    int ans = 0;
    for (int i = 0; i < a.length; i++) {
        bool[char] m;
        m[a[i]] = m[b[i]] = m[c[i]] = true;
        ans += m.keys.length - 1;
    }
    return ans;
}

void main() {
    readint;
    string a = read!string;
    string b = read!string;
    string c = read!string;
    writeln(calc(a, b, c));
}
