import numpy as np

S = list(map(int, eval(input())))



tmp = [0]*len(S)

if S[0] == 1:

    for ii in range(0,len(S),2):

        tmp[ii] = 1

else:

    for ii in range(1,len(S),2):

        tmp[ii] = 1



A = []

for ii in range(len(tmp)):

    A.append(S[ii]-tmp[ii])

    

count = np.count_nonzero(A)



print(count)
S = list(map(int, eval(input())))



count = 0

tmp = S[0]

for ii in S:

    if ii != tmp:

        count += 1

    if tmp == 1:

        tmp = 0

    else:

        tmp = 1





print(count)
import numpy as np

S = list(map(int, eval(input())))
tmp = [0] * len(S)
if S[0] == 1:
    for ii in range(0, len(S), 2):
        tmp[ii] = 1
else:
    for ii in range(1, len(S), 2):
        tmp[ii] = 1
A = []
for ii in range(len(tmp)):
    A.append(S[ii] - tmp[ii])
count = np.count_nonzero(A)
print(count)

S = list(map(int, eval(input())))
count = 0
tmp = S[0]
for ii in S:
    if ii != tmp:
        count += 1
    if tmp == 1:
        tmp = 0
    else:
        tmp = 1
print(count)

-import numpy as np - -tmp = [0] * len(S) -if S[0] == 1: -    for ii in range(0, len(S), 2): -        tmp[ii] = 1 -else: -    for ii in range(1, len(S), 2): -        tmp[ii] = 1 -A = [] -for ii in range(len(tmp)): -    A.append(S[ii] - tmp[ii]) -count = np.count_nonzero(A) +count = 0 +tmp = S[0] +for ii in S: +    if ii != tmp: +        count += 1 +    if tmp == 1: +        tmp = 0 +    else: +        tmp = 1