S = eval(input())

T = eval(input())

cnt = 0



for i, s in enumerate(S):

    if s != T[i]:

        cnt += 1



print(cnt)
S = eval(input())

T = eval(input())



cnt = 0

for i in range(len(S)):

    if S[i] != T[i]:

        cnt += 1



print(cnt)
S = eval(input())
T = eval(input())
cnt = 0
for i, s in enumerate(S):
    if s != T[i]:
        cnt += 1
print(cnt)

S = eval(input())
T = eval(input())
cnt = 0
for i in range(len(S)):
    if S[i] != T[i]:
        cnt += 1
print(cnt)

-for i, s in enumerate(S): -    if s != T[i]: +for i in range(len(S)): +    if S[i] != T[i]: