mod = 998244353 def main(): import sys input = sys.stdin.readline N = int(input()) S = input().rstrip('\n') T = input().rstrip('\n') ans = 0 for s, t in zip(S, T): if s != t: ans += 1 if ans & 1: ans += 1 ans2 = 0 for s, t in zip(S, T[::-1]): if s != t: ans2 += 1 if ans2 == 0: ans2 += 1 if ans2 & 1 == 0: ans2 += 1 print(min(ans, ans2)) if __name__ == '__main__': main()