#include <bits/stdc++.h>
using namespace std;
int solve() {
  long long int n;
  cin >> n;
  string s1, s2;
  cin >> s1 >> s2;
  long long int count = 0;
  char temp;
  for (int i = 0; i < n - 1; i++) {
    if (s1[i] == s2[i + 1] && s1[i] != s2[i] && s1[i + 1] == s2[i] &&
        s1[i + 1] != s2[i + 1]) {
      temp = s1[i];
      s1[i] = s1[i + 1];
      s1[i + 1] = temp;
      count++;
    }
  }
  for (int i = 0; i < n; i++) {
    if (s1[i] != s2[i]) {
      count += 1;
    }
  }
  cout << count << endl;
  return 0;
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(NULL);
  cout.tie(NULL);
  long long int t = 1;
  while (t--) {
    solve();
  }
  return 0;
}
