Help me in solving ST12 problem

My issue

output is not correct

My code

t = int(input())
for _ in range(t):
    n = int(input())
    S = input()
    R = input()

    count = 0
    for i in range(n):
        if S[i] == R[i]:
            count += 1
    if count % 2 == 1:
        print(1)
    else:
        print(0)

Learning course: Python with Data structures
Problem Link: Practice Problem in - CodeChef