import numpy as np



s = list(str(eval(input())))



if len(s) % 2 == 1:

  c = len(s) // 2

  del s[c]



half_len = int(len(s)/2)

h = s[:half_len]

t = s[-half_len:]

t.reverse()



count = 0

for i in range(0, half_len):

  if h[i] != t[i]:

    count = count + 1

print(count)
s = list(str(eval(input())))

 

half_len = int(len(s)/2)

h = s[:half_len]

t = s[-half_len:]

t.reverse()

 

count = 0

for i in range(0, half_len):

  if h[i] != t[i]:

    count = count + 1

print(count)
import numpy as np

s = list(str(eval(input())))
if len(s) % 2 == 1:
    c = len(s) // 2
    del s[c]
half_len = int(len(s) / 2)
h = s[:half_len]
t = s[-half_len:]
t.reverse()
count = 0
for i in range(0, half_len):
    if h[i] != t[i]:
        count = count + 1
print(count)

s = list(str(eval(input())))
half_len = int(len(s) / 2)
h = s[:half_len]
t = s[-half_len:]
t.reverse()
count = 0
for i in range(0, half_len):
    if h[i] != t[i]:
        count = count + 1
print(count)

-import numpy as np - -if len(s) % 2 == 1: -    c = len(s) // 2 -    del s[c]