s = input()

n = len(s)

sum = 0

l = s[:n // 2]
l = [x for x in l]
r = s[n // 2:]
r = [x for x in reversed(r)]

for (x, y) in zip(l, r):
    if x != y:
        sum += 1

print(sum)

dbf7189440b0f9e7b568d152fee5654a15e96241
<mask token>

<mask token>
for x, y in zip(l, r):
    if x != y:
        sum += 1
print(sum)

s = input()
n = len(s)
sum = 0
l = s[:n // 2]
l = [x for x in l]
r = s[n // 2:]
r = [x for x in reversed(r)]
for x, y in zip(l, r):
    if x != y:
        sum += 1
print(sum)

s = input()

n = len(s)

sum = 0

l = s[:n // 2]
l = [x for x in l]
r = s[n // 2:]
r = [x for x in reversed(r)]

for (x, y) in zip(l, r):
    if x != y:
        sum += 1

print(sum)
