#include<bits/stdc++.h>

using namespace std;

int arr[10][10];

int main() {
    ios_base::sync_with_stdio(0);
    string s, t;
    cin >> s >> t;
    map<char, int> m;
    m['A'] = 0;
    m['T'] = 1;
    m['C'] = 2;
    m['G'] = 3;
    for(int i=0; i < s.size(); i++) {
        if(s[i] != t[i]) {
            arr[m[s[i]]][m[t[i]]]++;
        }
    }
    int res=0;
    for(int i=0; i < 4; i++) {
        for(int j=0; j < 4; j++) {
            if(i == j) {
                continue;
            }
            if(arr[i][j] > 0) {
                int r = arr[i][j];
                arr[i][j] = 0;
                // cout << i << " " << j << " " << r << "\n";
                res+=r;
                for(int k=0; k < 4; k++) {
                    if(arr[k][i] > r) {
                        arr[k][i]-=r;
                        if(k != j) {
                            arr[k][j]+=r;
                        }
                        r=0;
                    } else {
                        r-=arr[k][i];
                        if(k != j) {
                            arr[k][j]+=arr[k][i];
                        }
                        arr[k][i] = 0;
                    }
                }
                // for(int x=0; x < 4; x++) {
                //     for(int y=0; y< 4; y++) {
                //         cout << arr[x][y] << " ";
                //     }
                //     cout << "\n";
                // }
                // cout << "\n";
            }
        }
    }
    cout << res << "\n";
}
