peterverebics/CodeNet_Python_118 huggingface dataset:
a,b,c=map(int,input().split())
if a==b==c and a%2==0:
    print(-1)
    exit()
ans=0
while a%2==b%2==c%2==0:
    x=(a+b)//2
    y=(b+c)//2
    z=(c+a)//2
    a=y
    b=z
    c=a
    ans+=1
print(ans)
import sys

sys.setrecursionlimit(10 ** 6)
INF = float("inf")
MOD = 10 ** 9 + 7


def input():
    return sys.stdin.readline().strip()


def main():
    A, B, C = map(int, input().split())

    for i in range(1000):
        if A % 2 or B % 2 or C % 2:
            print(i)
            return

        a = (B + C) // 2
        b = (A + C) // 2
        c = (A + B) // 2
        A = a
        B = b
        C = c

    print(-1)


if __name__ == "__main__":
    main()
import sys


inint = lambda: int(sys.stdin.readline())
inintm = lambda: map(int, sys.stdin.readline().split())
inintl = lambda: list(inintm())
instrm = lambda: map(str, sys.stdin.readline().split())
instrl = lambda: list(instrm())

a, b, c = inintm()

if a == b == c == 1:
    print(0)
    exit()

if a == b == c:
    print(-1)
    exit()

ans = 0

while a % 2 == b % 2 == c % 2 == 0:
    d = a
    e = b
    f = c
    a = e/2 + f/2
    b = d/2 + f/2
    c = d/2 + e/2
    ans += 1

print(ans)
A,B,C=map(int,input().split())
if A==B==C:
    print(0 if A%2 else -1)
else:
    count=0
    while A%2==B%2==C%2==0:
        A,B,C=(B+C)/2,(C+A)/2,(A+B)/2
        count+=1
    print(count)
import sys
a, b, c = [int(w) for w in input().split()]

ans = 0


def is_fin(a, b, c):
    global ans
    if a % 2 or b % 2 or c % 2:
        return True
    elif a == b == c:
        ans = -1
        return True
    else:
        return False


while not is_fin(a, b, c):
    ta = (b+c)/2
    tb = (a+c)/2
    tc = (a + b) / 2
    a, b, c = ta, tb, tc
    ans += 1

print(ans)
import collections
import sys
import numpy as np
sys.setrecursionlimit(1000000000)
from heapq import heapify,heappop,heappush,heappushpop
MOD = 10**9+7
import itertools
import math

a,b,c = map(int,input().split())
if a%2 == 0 and b%2 == 0 and c%2 == 0 and a == b and b == c:
    print(-1)
    sys.exit()
else:
    cnt = 0
    while True:
        if a%2 == 1 or b%2 ==1 or c%2 == 1:
            break
        a,b,c = b//2 + c//2,a//2+c//2,a//2+b//2
        cnt += 1    
    print(cnt)
a,b,c=map(int,input().split())
if a==b==c:
    if a%2==b%2==c%2==0:
        print(-1)
    else:
        print(0)
    exit()
cnt=0
while a%2==b%2==c%2:
    A=a//2
    B=b//2
    C=c//2
    a,b,c=B+C,A+C,A+B
    cnt+=1
print(cnt)
a, b, c = map(int,input().split())
count = 0
def exchange(a, b, c, count):
    a, b, c = int((b+c)/2), int((a+c)/2), int((a+b)/2)
    count += 1
    if a % 2 != 0 or b % 2 != 0 or c % 2 != 0:
        return a, b, c, count
    else:
        return exchange(a, b, c, count)
if a % 2 != 0 or b % 2 != 0 or c % 2 != 0:
    print(0) 
elif a == b == c:
    print(-1)
else:
    aa, bb, cc, count = exchange(a, b, c, count)
    print(count)
def main():
  a,b,c = map(int,input().split())
  s = [a,b,c]

  cnt = 0
  while (a % 2 == 0) and (b % 2 == 0) and (c % 2 == 0):
    
    a1,b1,c1 = a,b,c
    a = (b1+c1)//2
    b = (a1+c1)//2
    c = (a1+b1)//2
    
    if [a,b,c] == s:
      return -1
    
    cnt += 1
    #print(a,b,c)
    
  return cnt    
    

ans = main()
print(ans)
a,b,c=map(int,input().split())
if a==b==c and a%2==0:
  print(-1)
else:
  res=0
  while a%2==b%2==c%2==0:
    a,b,c=(b+c)/2,(c+a)/2,(a+b)/2
    res+=1
  print(res)
import sys
a, b, c = map(int, input().split())

if a == b and b == c:
    print(-1 if a % 2 == 0 else 0)
    sys.exit(0)

i = 0
while a % 2 == 0 and b % 2 == 0 and c % 2 == 0:
    a, b, c = (b + c) / 2, (c + a) / 2, (a + b) / 2
    i += 1

print(i)
def myAnswer(A:int,B:int,C:int) ->int:
   if(A == B and B == C):
      if(A % 2 == 0):
         return -1
      else:
         return 0
   counter = 0
   while A%2 == 0 and B%2 == 0 and C%2 == 0:
      A, B, C = ((B//2 + C//2), (A//2 + C//2), (A//2 + B//2))
      counter += 1
   return counter

def modelAnswer():
   tmp=1
def main():
   A,B,C = map(int,input().split())
   print(myAnswer(A,B,C))

if __name__ == '__main__':
   main()
a=list(map(int,input().split()))
cnt=0
tmp=[0]*3

while a[0]%2==0 and a[1]%2==0 and a[2]%2==0:
  if a[0]==a[1]==a[2]:
    cnt=-1
    break
  else:
    tmp[0]=a[1]//2+a[2]//2
    tmp[1]=a[0]//2+a[2]//2
    tmp[2]=a[0]//2+a[1]//2
    a[0],a[1],a[2]=tmp[0],tmp[1],tmp[2]
  cnt+=1
print(cnt)
A, B, C = map(int, input().split())
ans = 0
while A%2 == 0 and B%2 == 0 and C%2 ==0:
    ans += 1
    a, b, c = A//2, B//2, C//2
    A = b+c
    B = a+c
    C = a+b
    if ans == 100: break
if ans == 100:
    print(-1)
else:
    print(ans)
A, B, C = map(int, input().split())
ans = 0
while True:
    if A % 2 == 1 or B % 2 == 1 or C % 2 == 1:
        break
    if A == B and B == C and C == A:
        ans = -1
        break
    A, B, C = B // 2 + C // 2, A // 2 + C // 2, A // 2 + B // 2
    ans += 1
print(ans)
A, B, C = map(int, input().split())
res = 0

if (A == B == C) and all([A % 2 ==0, B % 2 == 0, C % 2 ==0]):
  res = -1
else:
  while all([A % 2 ==0, B % 2 == 0, C % 2 ==0]):
    at, bt, ct = A/2, B/2, C/2
    A = bt + ct
    B = at + ct
    C = at + bt
    res += 1

print(res)
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10 ** 7)

a, b, c = map(int, input().split())

ans = 0
pattern = set()
while a % 2 == 0 and b % 2 == 0 and c % 2 == 0:
    p = tuple(sorted((a, b, c)))
    if p in pattern:
        print(-1)
        sys.exit(0)
    pattern.add(p)
    a, b, c = (b + c) // 2, (a + c) // 2, (a + b) // 2
    ans += 1

print(ans)
abc = list(map(int,input().split()))
lis=[abc]
ans=0
def ch(x):
  for i in x:
    if i%2==1:
      return -1
  return 1
def sw(x):
  ret=[]
  ret.append(x[2]/2+x[1]/2)
  ret.append(x[0]/2+x[2]/2)
  ret.append(x[0]/2+x[1]/2)
  return ret
def check(a,l):
  for x in l:
    if a==x:
      return 1
  return 0
while True:
  if ch(abc)==-1:
    break
  abc=sw(abc)
  if check(abc,lis):
    ans=-1
    break
  lis.append(abc)
  ans+=1
  
print(ans)
# agc014_a.py]
A, B, C = map(int,input().split())
cnt = 0
inf = 10**2
for i in range(inf):
    if A%2==0 and B%2==0 and C%2==0: 
        a = (B+C)//2
        b = (A+C)//2
        c = (B+A)//2
        A = a
        B = b
        C = c
        cnt += 1
    else:
        break
if cnt == inf:
    cnt = -1
print(cnt)
a,b,c = map(int,input().split())
ans = 0
flag = True

while flag == True:
  if a%2 == 0 and b%2 == 0 and c%2 == 0:
    if (a==b==c):
      ans = -1
      break
    
    ans += 1
    at=a
    bt=b
    ct=c
    a = int(bt/2+ct/2)
    b = int(at/2+ct/2)
    c = int(at/2+bt/2)
  else:
    flag = False
    break
  
print(ans)
A, B, C = map(int, input().split())
cnt=0
memo=[]
while True:
    tmp = (A,B,C)
    if (A%2==0 and B%2==0 and C%2==0):
        if tmp not in memo:
            memo.append(tmp)
            cnt+=1
            A,B,C = (B+C)//2, (C+A)//2, (A+B)//2
        else:
            cnt=-1
            break
    else:
        break
print(cnt)
A,B,C=map(int,input().split())

if A==B==C and A%2==0:
    print(-1)
else:
    K=0
    while (A%2)+(B%2)+(C%2)==0:
        A,B,C=(B+C)//2,(C+A)//2,(A+B)//2
        K+=1
    print(K)
x,y,z= map(int,input().split())
A = []
ans = 0
A.append([x,y,z])
while True:
    if x%2==0 and y%2==0 and z%2==0:
        ans+=1
        x,y,z=((y+z)//2),((z+x)//2),((y+x)//2)
        
        if [x,y,z] in A:
        	ans = -1
        	break
        
    
    A.append([x,y,z])
    if x%2==0 and y%2==0 and z%2==0:
        continue
    else:
      break
    
print(ans)
A,B,C = map(int, input().split())

count = 0
while(A%2==0 and B%2==0 and C%2==0):
  if A==B==C:
    count = -1
    break
    
  tot = A+B+C
  A = (tot-A)/2
  B = (tot-B)/2
  C = (tot-C)/2
  count+=1

print(count)
# 解答AC

A,B,C = map(int, input().split())

is_even = lambda n: True if n % 2 == 0 else False

if A == B == C:
    if A % 2 == 0: print(-1)
    else: print(0)
else:
    cnt = 0
    while is_even(A) and is_even(B) and is_even(C):
        cnt += 1
        A,B,C = (B + C) // 2, (A + C) // 2, (A + B) // 2
    print(cnt)
from sys import stdin

a,b,c = [int(x) for x in stdin.readline().rstrip().split()]
count = 0
num = 0

while True:
    if a%2 == 1 or b%2 == 1 or c%2 == 1:
        print(count)
        exit()
    elif a==b==c:
        print(-1)
        exit()
    else:
        a,b,c = b//2+c//2,c//2+a//2,a//2+b//2
        count += 1
    num += 1
a,b,c = map(int,input().split())
if a==b==c and a%2==1:
    print(0)
elif a==b==c and a%2==0:
    print("-1")
else:
    cnt = 0
    while all(i&1==0 for i in [a,b,c]):
        A = a
        B = b
        C = c
        a = (B+C)//2
        b = (A+C)//2
        c = (A+B)//2
        cnt += 1
    print(cnt)
A, B, C = map(int, input().split())
count = 0
fA = A
fB = B
while A%2 == 0 and B%2 == 0 and C%2 == 0:
    hA = A/2
    hB = B/2
    hC = C/2
    A = hB + hC
    B = hA + hC
    C = hA + hB
    count += 1
    if A == fA and B == fB:
        count = -1 
        break

print(count)
import sys
A, B, C = map(int, input().split())
ans = 0

if A == B == C and not A == 1:
    print(-1)
    sys.exit()

while True:
    if A % 2 == 0 and B % 2 == 0 and C % 2 == 0:
        t_A, t_B, t_C = A, B, C
        A = (t_B + t_C) // 2
        B = (t_C + t_A) // 2
        C = (t_A + t_B) // 2
        ans += 1
    else:
        print(ans)
        break
a, b, c = map(int, input().split())
ans = 0
if a==b==c and a%2==0 and b%2==0 and c%2==0:
    print(-1)
else:
    while a%2==0 and b%2==0 and c%2==0:
        aa = b//2+c//2
        bb = c//2+a//2
        cc = a//2+b//2
        a = aa
        b = bb
        c = cc
        ans += 1
    print(ans)
A, B, C = map(int, input().split())
if A == B == C and A%2 == 0:
  print(-1)
else:
  D = 0
  while A%2 == 0 and B%2 == 0 and C%2 == 0:
    D += 1
    AA = B/2 + C/2
    BB = A/2 + C/2
    CC = A/2 + B/2
    A = AA
    B = BB
    C = CC
  print(D)
A, B, C = map(int, input().strip().split())
ans = 0
while (A != B or B != C) and (A % 2) + (B % 2) + (C % 2) == 0:
  A, B, C = (B + C) // 2, (A + C) // 2, (A + B) // 2
  ans += 1
if (A % 2) + (B % 2) + (C % 2) == 0 and A == B == C:
  ans = -1
print(ans)
A, B, C = map(int, input().split())

cnt = 0
if(A==B==C and A%2 == 0):
    print("-1")
else:
    while(A%2 == 0 and B%2 == 0 and C%2 == 0):
        tmpA = A
        tmpB = B
        tmpC = C
        cnt += 1
        A = tmpB//2+tmpC//2    
        B = tmpA//2+tmpC//2
        C = tmpA//2+tmpB//2
    print(cnt)
*a,=map(int,input().split())
b=[bin(a[i+1]-a[i])[::-1].find('1')for i in (0,1)]
print((max(b)*(b[0]*b[1]<0) or min(b))*(1-sum(a)%2))
a,b,c = map(int,input().split())
res = 0
while True:
    if a%2!=0 or b%2!=0 or c%2!=0:
        break
    elif a==b==c:
        res = -1
        break
    else:
        res += 1
        a,b,c = (b+c)//2, (c+a)//2, (a+b)//2
print(res)
A, B, C = map(int, input().split())

if A == B == C and A%2==0:
    print(-1)
else:
    cnt = 0
    while A%2 == B%2 == C%2 == 0:
        x = (B+C)//2
        y = (A+C)//2
        z = (A+B)//2
        A = x
        B = y
        C = z
        cnt += 1
    print(cnt)
A, B, C = map(int, input().split())

if A % 2 or B % 2 or C % 2:
    print(0)
    exit(0)


def solve(n):
    i = 0
    while(n % 2 == 0):
        n = n // 2
        i += 1
    return(i)


a = solve(A+B)
b = solve(B+C)
c = solve(C+A)
if a == b and b == c:
    print(-1)
else:
    print(min(a, b, c))
a,b,c = map(int,input().split())
ans = 0

if a == b and a == c and a%2 == 0:
  print("-1")
elif a == b and a == c and a%2 == 0:
  print(0)
else:
  while a%2 == 0 and b%2 == 0 and c%2 == 0:
    ans += 1
    aa = b/2 + c/2
    bb = a/2 + c/2
    cc = a/2 + b/2
    a = aa
    b = bb
    c = cc
  print(ans)
a, b, c = map(int, input().split())
ans = 0
while True:
  if a%2 == 1 or b%2 == 1 or c%2 == 1:
    break
  if a == b == c:
    ans = -1
    break
  na = (b+c) // 2
  nb = (a+c) // 2
  nc = (a+b) // 2
  ans += 1
  a, b, c = na, nb, nc
  #print(na,nb,nc,ans)
print(ans)
A, B, C = map(int, input().split())

if A % 2 == 1 or B % 2 == 1 or C % 2 == 1:
    print(0)
    exit()
    
diff1 = abs(A-B)
diff2 = abs(B-C)

if diff1 == 0 and diff2 == 0:
    print(-1)
    exit()

ans = 0
while diff1 % 2 == 0 and diff2 % 2 == 0:
    ans += 1
    diff1 //= 2
    diff2 //= 2

print(ans)
def main():
	A, B, C = map(int, input().split())
	even_flag = True
	count = 0

	while even_flag:
		if A % 2 == 1 or B % 2 == 1 or C % 2 == 1:
			even_flag = False
			break

		elif A == B and B == C and A == C:
			break

		A, B, C = (B // 2 + C // 2), (A // 2 + C // 2), (A // 2 + B // 2)
		count += 1

	if even_flag:
		print(-1)
	else:
		print(count)
		
if __name__ == "__main__":
	main()
a, b, c = map(int, input().split())
cnt = 0
while True:
    if a % 2 or b % 2 or c % 2:
        break
    if a == b == c:
        cnt = -1
        break
    a, b, c = b // 2 + c // 2, c // 2 + a // 2, a // 2 + b // 2
    cnt += 1
print(cnt)
a, b, c = map(int, input().split())

if a != 1 and a == b == c:
  print(-1)
  exit()
  
result = 0

while True:
  if any([a & 1, b & 1, c & 1]):
    break
    
  a2 = a // 2
  b2 = b // 2
  c2 = c // 2
  a = b2 + c2
  b = a2 + c2
  c = a2 + b2
  result += 1

print(result)
A, B, C = map(int, input().split())

if A == B and B == C and A % 2 == 0:
    print('-1')
    exit()

count = 0
for i in range(10**9):
    if A % 2 == 1 or B % 2 == 1 or C % 2 == 1:
        break
    count += 1
    a = A
    b = B
    c = C
    A = b // 2 + c // 2
    B = a // 2 + c // 2
    C = a // 2 + b // 2

print(count)
a,b,c=map(int,input().split())
if a%2!=0 or b%2!=0 or c%2!=0:
    print(0)
elif a==b==c:
    print(-1)
else:
    total=0
    while True:
        x=a/2
        y=b/2
        z=c/2
        a=y+z
        b=x+z
        c=x+y
        total+=1
        if a%2!=0 or b%2!=0 or c%2!=0:
            print(total)
            break
A, B, C = map(int, input().split())

if A % 2 == 1 and B % 2 == 1 and C % 2 == 1:
    print(0)
    exit()
elif A == B and B == C:
    print('-1')
    exit()
else:
    ans = 0
    while A % 2 != 1 and B % 2 != 1 and C % 2 != 1:
        a = B//2+C//2
        b = C//2+A//2
        c = A//2+B//2
        A, B, C = a, b, c
        ans += 1
print(ans)
N = list(map(int, input().split()))
N2 = [0,0,0]
ans = 0
while True:
    for i in range(3):
        if  not N[i] %2 == 0:
            print(ans)
            exit()
    N2[0] = (N[1] + N[2]) /2
    N2[1] = (N[0] + N[2]) /2
    N2[2] = (N[0] + N[1]) /2
    #print(N2)
    if N == N2:
        print('-1')
        exit()
    N = N2.copy()
    ans += 1
a, b, c = map(int, input().split())

if a % 2 == 0 and b % 2 == 0 and c % 2 == 0 and a == b == c:
    print(-1)
    exit()

ans = 0
while a % 2 == 0 and b % 2 == 0 and c % 2 == 0:
    a_tmp = b // 2 + c // 2
    b_tmp = a // 2 + c // 2
    c_tmp = a // 2 + b // 2
    a, b, c = a_tmp, b_tmp, c_tmp
    ans += 1

print(ans)
a, b, c = map(int, input().split())

test = [[a,b,c]]
count = 0
while a%2 == b%2 == c%2 == 0:
    at = a
    bt = b
    ct = c
    a = bt//2 + ct//2
    b = ct//2 + at//2
    c = at//2 + bt//2
    count+=1
    if [a,b,c] in test:
        count = -1
        print(count)
        break
    else:
        test.append([a,b,c])
if count != -1:
    print(count)
A,B,C = map(int,input().split())
ans = 0
if A == B == C:
  if A%2 != 0 or B%2 != 0 or C%2 != 0:
    pass
  else:
    ans = -1
else:
  while A%2 == 0 and B%2 == 0 and C%2 == 0:
    A,B,C = B//2+C//2,A//2+C//2,A//2+B//2
    ans += 1
print(ans)
def f(a, b, c):
    if a > 1 and a == b and a == c:
        print(-1)
    else:
        count = 0
        for i in range(100):
            if a%2 or b%2 or c%2:
                break
            a, b, c = b//2 + c//2, a//2 + c//2, a//2 + b//2
            count += 1
        print(count)

a, b, c = map(int, input().split())
f(a, b, c)
a, b, c = map(int, input().split())
if a%2 == 0 and a == b and c == b:
    print(-1)
else:
    ans = 0
    while a%2 == b%2 == c%2 ==0:
        ans += 1
        a,b,c=(b+c)/2,(c+a)/2,(a+b)/2
    print(ans)
a,b,c = map(int,input().split())
ans = 0
while True:
    if a%2 ==1 or b%2 == 1 or c%2 == 1:
        ans = 0
        break
    ans+=1
    na = (b+c)//2
    nb = (c+a)//2
    nc = (a+b)//2
    if a == b and b == c:
        ans = -1
        break
    if na%2 == 1 or nb%2 == 1 or nc%2 == 1:
        break
    a,b,c, = na,nb,nc
print(ans)
A, B, C = map(int, input().split())
cnt = 0
while True:
    if A % 2 != 0 or B % 2 != 0 or C % 2 != 0:
        print(cnt)
        break
    elif A == B and A == C:
        print(-1)
        break
    else:
        A, B, C = (B+C)//2, (C+A)//2, (A+B)//2
        cnt += 1
a,b,c = map(int,input().split())
if a == b == c:
  if a%2 == b%2 == c%2 == 0:
    print(-1)
  else:
    print(0)
else:
  t = 0
  while t > -1:
    if a%2 == 1 or b%2 == 1 or c%2 == 1:
      break
    (a,b,c) = ((b+c)//2,(a+c)//2,(a+b)//2)
    t += 1
  print(t)
A,B,C = map(int,input().split())
if A == B == C and A%2 == 0:
  print(-1)
elif A%2 == 1 or B%2 == 1 or C%2 == 1:
  print(0)
else:
  c = 0
  while A%2 == B%2 == C%2 == 0:
    A0 = A
    B0 = B
    C0 = C
    A = (B0+C0)/2
    B = (C0+A0)/2
    C = (A0+B0)/2
    c += 1
  print(c)
cookie = list(map(int, input().split()))
sc = sum(cookie)
cnt = 0
if cookie[0] == cookie[1] and cookie[1] == cookie[2] and cookie[0]%2 == 0:
    print(-1)
    exit()
memo = [0]*3
while cookie[0]%2 == 0 and cookie[1]%2 == 0 and cookie[2]%2 == 0:
    memo[0] = (cookie[1] + cookie[2]) // 2
    memo[1] = (cookie[0] + cookie[2]) // 2
    memo[2] = (cookie[1] + cookie[0]) // 2
    for i in range(3):
        cookie[i] = memo[i]
    cnt += 1

print(cnt)
A,B,C=map(int,input().split())
if A==B and B==C and A%2==0:
	print(-1)
	exit()
else:
	count=0
	while(1):
		if A%2==1 or B%2==1 or C%2==1:
			print(count)
			exit()
		else:
			a=A//2
			b=B//2
			c=C//2
			A=b+c
			B=a+c
			C=a+b
			count+=1
a,b,c=map(int,input().split())
e=a-b|b-c
print((e!=b%2)*(e^e-1).bit_length()-1)
a,b,c = map(int,input().split())
ans = 0
comb = set()
while a%2==0 and b%2==0 and c%2==0:
    x = (b+c)//2
    y = (a+c)//2
    z = (b+c)//2
    if (x,y,z) in comb:
        ans = -1
        break
    ans += 1
    comb.add((x,y,z))
    a,b,c = x,y,z
print(ans)
A,B,C=map(int,input().split())
if (A==B)and(B==C)and(A%2==0):
    print("-1")
else:
    count=0
    while True:
        if (A%2==0)and(B%2==0)and(C%2==0):
            a=(B+C)/2
            b=(A+C)/2
            c=(A+B)/2
            A=a
            B=b
            C=c
            count=count+1
        else:
            break
    print(count)
A, B, C = map(int, input().split())

ans = 0
if A&1 or B&1 or C&1:
    print(ans)
    exit(0)

if A == B == C:
    print(-1)
    exit(0)

while True:
    if A&1 or B&1 or C&1:
        break
    nA = B//2 + C//2
    nB = A//2 + C//2
    nC = B//2 + A//2
    ans += 1
    A = nA
    B = nB
    C = nC

print(ans)
A, B, C = map(int,input().split())

empty = [0] * 3
count = 0
if A == B == C and A % 2 == 0 and B % 2 == 0 and C % 2 == 0:
    print(-1) 
elif (A % 2 != 0) or (B % 2 != 0) or (C % 2 != 0):
    print(0)
else:
    while A % 2 == 0 and B % 2 == 0 and C % 2 == 0: 
        count += 1
        A_ = A//2
        B_ = B//2
        C_ = C//2
        A = B_ + C_
        B = A_ + C_
        C = A_ + B_

    print(count)
#11
import sys
A,B,C = map(int,input().split())

a1,b1,c1,cou= 0,0,0,0



while A%2 == 0 and B%2 == 0 and C%2 == 0:
    if A == B == C:
        print("-1")
        sys.exit()
    a1 = int(A/2) 
    b1 = int(B/2) 
    c1 = int(C/2) 
    A = b1+c1
    B = a1+c1
    C = a1+b1
    cou += 1
    
print(cou)
A, B, C = map(int, input().split())
cnt = 0

if A == B == C and A % 2 == 0:
    cnt = -1
else:
    while A%2 == 0 and B%2 == 0 and C%2 == 0:
        A, B, C = int((B+C)/2), int((A+C)/2), int((A+B)/2)
        cnt += 1

print(cnt)
import sys
import numpy as np
a, b, c = [int(i) for i in sys.stdin.readline().split()]
ls = np.array([a, b, c])
arr = np.array([[0, 0.5, 0.5],
                [0.5, 0, 0.5],
                [0.5, 0.5, 0]])
cnt = 0
while sum(ls % 2) == 0:
    if ls[0] == ls[1] == ls[2]:
        cnt = -1
        break
    ls = ls.dot(arr)
    cnt += 1
print(cnt)
A, B, C = map(int, input().split())
if A == B == C:
  if A % 2 == 0:
    print(-1)
  else:
    print(0)
else:
  ans = 0
  while A % 2 == 0 and B % 2 == 0 and C % 2 == 0:
    p, q, r = A // 2, B // 2, C // 2
    A, B, C = q + r, p + r, p + q
    ans += 1
  print(ans)
a, b, c = map(int, input().split())
cnt = 0
while True:
  if a % 2 != 0 or b % 2 != 0 or c % 2 != 0:
    break
  if a == b == c:
    cnt = -1
    break
  k, l, m = a//2, b//2, c//2
  a = l + m
  b = k + m
  c = k + l
  cnt += 1
print(cnt)
import sys
input = sys.stdin.readline

# A - Cookie Exchanges
def is_even(a, b, c):
	cookies = [a, b, c]
	return all(c % 2 == 0 for c in cookies)


a, b, c = map(int, input().split())

for i in range(1000):
	if is_even(a, b, c):
		new_a = b//2 + c//2
		new_b = a//2 + c//2
		new_c = a//2 + b//2
		a, b, c = new_a, new_b, new_c
	else:
		print(i)
		exit()

print(-1)
a, b, c = map(int, input().split())
if a == b == c:
    if a % 2 == 0:
        print(-1)
    else:
        print(0)
else:
    cnt = 0
    while a % 2 == 0 and b % 2 == 0 and c % 2 == 0:
        a, b, c = (b+c)//2, (a+c)//2, (a+b)//2
        cnt += 1
    print(cnt)
A, B, C = map(int, input().split())

if A%2==1 or B%2==1 or C%2==1:
  print(0)
elif A==B and B==C:
  print(-1)
else:
  count = 0
  while True:
    if A%2==1 or B%2==1 or C%2==1:
      break
    count+=1
    A_tmp = B/2 + C/2
    B_tmp = A/2 + C/2
    C = A/2 + B/2
    A = A_tmp
    B = B_tmp
  print(count)
a, b, c = map(int, input().split()); i = 0
if a == b and b == c and a%2 == 0: print(-1)
else:
    while a%2 == 0 and b%2 == 0 and c%2 == 0:
        a, b, c = (b+c)//2, (c+a)//2, (a+b)//2; i += 1
    print(i)
a,b,c=map(int,input().split())
e=a-b|b-c
print((e!=b%2)*len(f'{e&-e:b}')-1)
a,b,c = map(int,input().split())
if a%2 == 1 or b%2 == 1 or c%2== 1 :
    print(0)
    exit()
elif a == b and b == c :
    print(-1)
    exit()
count = 0
while (a%2 == 0 and b%2 == 0 and c%2 == 0) :
    count += 1
    x = (a+b)/2
    y = (b+c)/2
    z = (c+a)/2
    a = x
    b = y
    c = z


print(count)
A,B,C=map(int,input().split())
if A==B==C and A%2==0:
  print(-1)
elif A%2==1 or B%2==1 or C%2==1:
  print(0)
else:
  c=0
  while A%2==B%2==C%2==0:
    A0=A
    B0=B
    C0=C
    A=(B0+C0)/2
    B=(C0+A0)/2
    C=(A0+B0)/2
    c+=1
  print(c)
a, b, c = map(int, input().split())
count = 0
for i in range(10**3):
    if a%2 != 0 or b%2 != 0 or c%2 != 0:
        print(count)
        exit()
    a, b, c = b/2 + c/2, a/2 + c/2, a/2 + b/2
    count += 1
print(-1)
def check(aa,bb,cc):
    if aa%2==0 and bb%2==0 and cc%2==0:
        return True
    else:
        return False

a,b,c = map(int, input().split())
if check(a,b,c):
    if a == b == c:
        print(-1)
        exit()

ans = 0
while check(a,b,c):
    _a = b // 2 + c // 2
    _b = a // 2 + c // 2
    _c = a // 2 + b // 2
    a = _a
    b = _b
    c = _c
    ans += 1
print(ans)
a, b, c = map(int, input().split())

counter = 0
while a%2==b%2==c%2==0:
    a, b, c = (b+c)//2, (a+c)//2, (a+b)//2
    counter += 1
    if counter > 100000:
        counter = -1
        break
print(counter)
A,B,C = map(int,input().split())

#print(A,B,C)

if A==B and B==C and A%2==1:
  print(0)
  
elif A==B and B==C:
  print(-1)
else:
  count=0
  while A%2==0 and B%2==0 and C%2==0:
    Ax=A/2
    Bx=B/2
    Cx=C/2
    #print(Ax,Bx,Cx)
    A = int(Bx+Cx)
    B = int(Cx+Ax)
    C = int(Ax+Bx)
    count +=1
    #print(A,B,C)
  print(count)
import sys
a,b,c = map(int,input().split())
ans = 0
pa = []
pb = []
while True:
  if a%2 == 1 or b%2 == 1 or c%2 == 1:
    break
  ans += 1
  lasta = a
  lastb = b
  lastc = c
  a = lastb/2 + lastc/2
  b = lasta/2 + lastc/2
  c = lasta/2 + lastb/2
  for i in range(len(pa)):
    if pa[i] == a:
      if pb[i] == b:
        print(-1)
        sys.exit()
  pa.append(a)
  pb.append(b)
print(ans)
A,B,C=map(int,input().split())
cnt=0
if A==B and B==C:
    if A%2==0:
        print(-1)
    else:
        print(0)
    exit()

while True:
    x=A
    y=B
    z=C
    if A%2!=0 or B%2!=0 or C%2!=0:
        break
    cnt+=1
    A=(y+z)//2
    B=(x+z)//2
    C=(x+y)//2
    #print(A,B,C)
print(cnt)