#include<iostream>
#include<cstring>
using namespace std;
string s, e;
void turn(int x){
s[x] = s[x] == 'o' ? '*' : 'o';
if(x + 1 < s.size())
s[x+1] = s[x+1] == 'o' ? '*' : 'o';
}
int main(){
cin >> s >> e;
int step = 0;
for(int i = 0; i < s.size(); i++){
if(s[i] != e[i]){
step++;
turn(i);
}
}
cout << step;
return 0;
}