num = (input())
odd = 0
even = 0
if (len(num)%2) != 0:
for i in range(len(num)):
if i%2 == 0:
odd += int(num[i])
else:
even += int(num[i])
else:
for i in range(len(num)):
if i%2 == 0:
even += int(num[i])
else:
odd += int(num[i])
print(abs(odd - even))
print(abs(sum(int(i)*(-1)**n for n,i in enumerate(input()))))