peterverebics/CodeNet_Python_118 huggingface dataset:
a, b, c = list(map(int, input().split()))

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

OK = True
count = 0

while OK:
    if a % 2 == 1 or b % 2 == 1 or c % 2 == 1:
        OK = False
        break
    diva = a / 2
    divb = b / 2
    divc = c / 2
    a = divb + divc
    b = divc + diva
    c = diva + divb
    count += 1

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

while a % 2 == 0 and b % 2 == 0 and c % 2 == 0:
    if a == b == c:
        print(-1)
        exit()
    a, b, c = (b + c) // 2, (c + a) // 2, (a + b) // 2
    ans += 1
print(ans)
a,b,c = list(map(int, input().split()))

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

ans=0    
while all(i&1==0 for i in [a,b,c]):
    a,b,c = (b+c)//2, (a+c)//2, (a+b)//2
    ans+=1

print(ans)
A, B, C = [int(i) for i in input().split()]
ans = 0
a, b, c = A, B, C
while(a % 2 == 0 and b % 2 == 0 and c % 2 == 0):
    ans += 1
    ha = int(a / 2)
    hb = int(b / 2)
    hc = int(c / 2)
    a = hb + hc
    b = hc + ha
    c = ha + hb
    if a == A and b == B and c == C:
        ans = -1
        break
print(ans)
a, b, c = map(int, input().split())

ba = a
bb = b
bc = c
ans = 0
while True:
    if a % 2 != 0 or b % 2 != 0 or c % 2 != 0:
        break

    ta = a//2
    tb = b//2
    tc = c//2
    a = tb+tc
    b = ta+tc
    c = ta+tb
    ans += 1

    if a == ba and b == bb and c == bc:
        ans = -1
        break

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

ans = 0

while True:
    if ans > 999999:
        print(-1)
        break
    elif a % 2 != 0 or b % 2 != 0 or c % 2 != 0:
        print(ans)
        break
    n_a = b/2 + c/2
    n_b = a/2 + c/2    
    n_c = a/2 + b/2
    a = n_a
    b = n_b
    c = n_c
    ans += 1
A,B,C=map(int,input().split())

t=0
while(True):
    if(A%2==1 or B%2==1 or C%2==1) :
        break
    a=(A+B)/2
    b=(B+C)/2
    c=(C+A)/2
    if(A==a and B==b and C==c):
        print(-1)
        exit()
    A=a
    B=b
    C=c
    t+=1
print(t)
import math

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

cnt = 0

if a == b == c and (a+b+c)%2 == 0:
    print(-1)
    exit()
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
        cnt += 1
print(cnt)
a,b,c=map(int,input().split())
num=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)
  num+=1
  if (num>10**7):
    print(-1)
    break
else:
  print(num)
A,B,C = map(int, input().split())

def all_even(a,b,c):
	if a%2 == 0 and b%2 == 0 and c%2 == 0:
		return True
	else:
		return False

cnt = 0

while all_even(A,B,C):
	if A == B == C:
		cnt = -1
		break
	cnt+=1
	A,B,C = (B+C)//2, (A+C)//2, (A+B)//2
	
print(cnt)
a, b, c = map(int, input().split())
cnt = 0
while True:
    if a == b == c and a%2 == 0:
        cnt = -1
        break
    elif a%2 != 0 or b%2 != 0 or c%2 != 0:
        break
    elif 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())
cnt = 0
while True:
    if A % 2 == 0 and B % 2 == 0 and C % 2 == 0:
        if A == B == C:
            print(-1)
            break
        else:
            a = A
            b = B
            c = C
            A = (b+c)//2
            B = (a+c)//2
            C = (a+b)//2
            cnt +=1
    else:
        print(cnt)
        break
a = list(map(int, input().split()))
count = 0
while all(x % 2 == 0 for x in a) and count <= 100000:
	b = [(sum(a) - x) // 2 for x in a]
	a = b
	count += 1
print(count if count <= 100000 else -1)
A, B, C = map(int, input().split())

AA, BB, CC = A, B, C
cnt = 0
while True:
    if (A % 2) | (B % 2) | (C % 2):
        print(cnt)
        exit(0)
    a, b, c = A // 2, B // 2, C // 2
    A, B, C = b + c, a + c, a + b
    cnt += 1
    if (A == B) & (B == C):
        print(-1)
        exit(0)
    if (A == AA) & (B == BB) & (C == CC):
        print(-1)
        exit(0)
if __name__ == "__main__":
    a, b, c = map(int, input().split())

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

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

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

for i in range(40):
    if a % 2 == 0 and b % 2 == 0 and c % 2 == 0:
        d = a // 2
        e = b // 2
        f = c // 2
        a = e + f
        b = d + f
        c = d + e
        ans += 1
    else:
        k = 0
        break

if k == 1:
    print(-1)
else:
    print(ans)
a,b,c=map(int, input().split())

cnt=0
for _ in range(10**5):
    if a%2==1 or b%2==1 or c%2==1:
        print(cnt)
        exit()
    a,b,c=b//2+c//2,c//2+a//2,a//2+b//2
    cnt+=1
print(-1)
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 > 26:
        counter = -1
        break
print(counter)
A, B, C = map(int, input().split())
ans = 0

while 1:
    if A%2 != 0 or B%2 != 0 or C%2 != 0:
        print(ans)
        break
    else:
        tmp = [B//2 + C//2, C//2 + A//2, A//2 + B//2]
        if tmp == [A,B,C]:
            print(-1)
            break
        else:
            A,B,C = tmp[0], tmp[1], tmp[2]
            ans += 1
a,b,c=map(int,input().split())
if a==b and a==c and a%2==0:
  print(-1)
else:
  cnt=0
  while a%2==0 and b%2==0 and c%2==0:
    cnt+=1
    k=a
    l=b
    a=(b+c)//2
    b=(k+c)//2
    c=(k+l)//2
  print(cnt)
a, b, c = map(int, input().split())
cnt = 0
total = a + b + c
while a % 2 == 0 and b % 2 == 0 and c % 2 == 0:
    if a == (total - a) // 2:
        cnt = -1
        break
    a = (total - a) // 2
    b = (total - b) // 2
    c = (total - c) // 2
    cnt += 1
print(cnt)
def resolve():
    a, b, c = map(int, input().split())
    ans = 0
    if a == b == c:
        print(-1)
        exit()
    if a%2 != 0 or b%2 != 0 or c%2 != 0:
        print(ans)
        exit()
    while (a%2 == 0 and b%2 == 0 and c%2 == 0):
        a, b, c = (b+c)//2, (a+c)//2 , (a+b)//2
        ans += 1
    print(ans)
resolve()
a, b, c = map(int, input().split())

a_tmp = 0
b_tmp = 0
c_tmp = 0

flag = 0
ans = 0

if a == b and b == c and c == a:
  ans = -1
else:
  while flag == 0:
    b_tmp += a/2
    c_tmp += a/2
    
    a_tmp += b/2
    c_tmp += b/2
    
    a_tmp += c/2
    b_tmp += c/2
    
    a = a_tmp
    b = b_tmp
    c = c_tmp
    
    ans += 1
    
    if a%2 == 1 or b%2 ==1 or c%2 ==1:
      flag = 1
print(ans)
A, B, C = list(map(int, input().split()))

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

ans = 0
while not any(n % 2 == 1 for n in [A, B, C]):
    A, B, C = (A + B) // 2, (B + C) // 2, (C + A) // 2
    ans += 1

print(ans)
A, B, C = map(int, input().strip().split())
ans = 0
while A != B and 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 == B == C:
  ans = -1
print(ans)
def main():
    A, B, C = map(int, input().split())

    ans = 0
    if (2 * A - B - C) == 0 and (2 * B - A - C) == 0 and (2 * C - A - B) == 0:
        print(-1)
    else:
        for i in range(10**9):
            if A % 2 == 1 or B % 2 == 1 or C % 2 == 1:
                print(ans)
                exit()

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

if __name__ == "__main__":
    main()
a, b, c = list(map(int, input().split(' ')))
cnt = 0
if a == b == c:
    cnt = -1  
else:
    while not (a%2 or b%2 or c%2):
        cnt += 1
        a,b,c=(b+c)/2,(a+c)/2,(a+b)/2

print(cnt)
a, b, c = map(int, input().split())
i = 0
if a == b == c:
    print(-1)
else:
    while a%2==0 and b%2==0 and c%2==0:
        at = a//2
        bt = b//2
        ct = c//2
        a = bt + ct
        b = at + ct
        c = at + bt
        i+=1
    print(i)
#!/usr/bin/env python

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

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

ans = 0 
while True:
    ta = a 
    tb = b 
    tc = c 
    a = (tb+tc)//2
    b = (tc+ta)//2
    c = (ta+tb)//2
    ans += 1
    if a%2 == 1 or b%2 == 1 or c%2 == 1:
        print(ans)
        exit()
a, b, c = map(int, input().split())
cnt = 0
if a == b and b == c:
  print(-1)
  exit()
while cnt >= 0:
  if a % 2 != 0 or b % 2 != 0 or c % 2 != 0:
    print(cnt)
    exit()
  else:
    a1 = (b + c) // 2
    b1 = (a + c) // 2
    c1 = (a + b) // 2
    a = a1
    b = b1
    c = c1
    cnt += 1
print(cnt)
a,b,c=map(int,input().split())
e=a-b|b-c
print(len(f'{e&-e:b}')-(e==b&1))
A, B, C = map(int, input().split())
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
if A == B == C:
    print(-1)
else:
    print(cnt)
A,B,C = map(int,input().split())
ans = 0
if A == B == C:
  print(-1)
else:
  while A % 2 == 0 and B % 2 == 0 and C % 2 == 0:
    n_A = (B + C) / 2
    n_B = (A + C) / 2
    n_C = (A + B) / 2
    A = n_A
    B = n_B
    C = n_C
    ans += 1
  print(ans)
a, b, c = list(map(int, input().split(' ')))
cnt = 0
if a == b == c:
    cnt = -1  
else:
    while (a+1)%2 or (b+1)%2 or (c+1)%2:
        cnt += 1
        a,b,c=(b+c)/2,(a+c)/2,(a+b)/2

print(cnt)
A,B,C = map(int,input().split())
ans = 0
if A == B == C or A%2 != 0 or B%2 != 0 or C%2 != 0:
  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,B/2+C/2
    ans += 1
print(ans)
a, b, c = map(int, input().split())
if a == b == c:
   print(-1)
   exit()

cnt = 0
while True:
   if a % 2 or b % 2 or c % 2:
      break
   cnt += 1
   next_a = b // 2 + c // 2
   next_b = a // 2 + c // 2
   next_c = a // 2 + b // 2
   a = next_a; b = next_b; c = next_c
print(cnt)
## A - Cookie Exchanges
A, B, C = map(int, input().split())
if A == B == C:
    ans = -1
else:
    ans = 0
    while A%2 == B%2 == C%2 == 0:
        a = (B+C) // 2
        b = (C+A) // 2
        c = (A+B) // 2
        A = a
        B = b
        C = c
        ans += 1
print(ans)
A,B,C = map(int,input().split())
if A == B and  B == C and C == A:
  print(-1)
else:
  count = 0
  while(A%2==0 and B%2 == 0 and C%2==0):
    A_ = A
    B_ = B
    A = (B+C)/2
    B = (A_+C)/2
    C = (A_+B_)/2
    print(A,B,C)
    count+=1
  print(count)
A, B, C = map(int, input().split())
count = 0
if A == B and B == C:
  print(-1)
  exit()

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
  count += 1
print(count)
A,B,C = map(int,input().split())
ans = 0
if A == B == C:
  print(-1)
else:
  while A % 2 == 0 and B % 2 == 0 and C % 2 == 0:
    n_A = (B + C) / 2
    n_B = (A + C) / 2
    n_C = (B + C) / 2
    A = n_A
    B = n_B
    C = n_C
    ans += 1
  print(ans)
import sys

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

count = 0
while True:
    a = B//2 + C//2
    b = C//2 + A//2
    c = A//2 + B//2
    count += 1
    if (A == B and B == C) or (A % 4 == 0 and B % 4 == 0 and C % 4 == 0):
        print('-1')
        sys.exit()
    if a % 2 == 1 or b % 2 == 1 or c % 2 == 1:
        break
    A = a
    B = b
    C = c

print(count)
A,B,C = map(int, input().split())
cnt = 0
if A == B and B == C:
    print(-1)
    exit()
while True:
    if A%2 or B%2 or C%2:
        print(cnt)
        break
    temp_a = A//2
    temp_b = B//2
    temp_c = C//2
    A += 2*temp_a + temp_b + temp_c
    B += 2*temp_b + temp_a + temp_c
    C += 2*temp_c + temp_a + temp_b
    cnt += 1
a, b, c = map(int, input().split())
 
if a == b == c:
    print(-1)

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 = list(map(int,input().split()))
cna = cnb = 0
a.sort()
x = a[2]-a[1]
y = a[1]-a[0]
while True:
    if x%2 == 0 and x != 0:
        cna += 1
        x //= 2
    else:
        break
while True:
    if y%2 == 0 and y != 0:
        cnb += 1
        y //= 2
    else:
        break
if cna == 0 and cnb == 0:
    print(-1)
else:
    print(min(cna,cnb))
import sys
a, b, c = [int(w) for w in input().split()]

ans = 0


def is_fin(a, b, c):
    global ans
    if a == b == c:
        ans = -1
        return True
    elif a % 2 or b % 2 or c % 2:
        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)
A,B,C= map(int,input().split())

if A==B==C:
    print('-1')
else:
    cnt = 0

    flag = True
    while flag:
        A, B, C = (B+C)//2, (A+C)//2, (A+B)//2
        cnt += 1
        if A%2==0 and B%2==0 and C%2==0:    
            continue
        else:
            flag = False

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

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

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 == b == c:
  if a % 2 == 0:
    print(-1)
  else:
    print(1)
else:
  ans = 0
  while a % 2 == 0 and b % 2 == 0:
    a1 = a
    b1 = b
    c1 = c
    a = (b1+c1)/2
    b = (a1+c1)/2
    c = (a1+b1)/2
    ans += 1
  print(ans)
a,b,c=map(int,input().rstrip().split(' '))
if(a==b and b==c):
	print(-1)
else:
	n=0
	while(a%2==0 and b%2==0 and c%2==0):
		n+=1
		tmp_a=(b+c)/2
		tmp_b=(a+c)/2
		tmp_c=(b+a)/2
		a=tmp_a
		b=tmp_b
		c=tmp_c
	print(n)
a,b,c = map(int,input().split(" "))
n = 0
if a == b == c:
  print(-1)
  exit()
for i in range(10**9):
  aa = a//2
  bb = b//2
  cc = c//2
  a = bb + cc
  b = aa + cc
  c = aa + bb
  n += 1
  if a % 2 == 1:
    break
  if b % 2 == 1:
    break
  if c % 2 == 1:
    break
print(n)
A, B, C = list(map(int, input().split()))
if A == B == C:
    print(-1)
    exit()
ans = 0
while True:
    if A % 2 == 0 and B % 2 == 0 and C % 2 == 0:
        ans += 1
        A, B, C = (B + C) // 2, (A + C) // 2, (A + B) // 2
    else:
        break
print(ans)
A,B,C = map(int, input().split())

def even(a):
	if a % 2 == 0:
		return True
	else:
		return False

if A == B and B == C:
	print("-1")
	
elif not (even(A) and even(B) and even(C)):
		print("0")

else:
	cnt = 0
	while even(A) and even(B) and even(C):
		tmp1, tmp2, tmp3 = A,B,C
		A = (tmp2+tmp3) // 2
		B = (tmp3+tmp1) // 2
		C = (tmp1+tmp2) // 2
		cnt += 1
	print(cnt)
a,b,c=map(int,input().split())
if a==b and b==c:
    print(-1)
else:
    ans=0
    while a%2==0 and b%2==0 and c%2==0:
        a0,b0,c0=(b+c)//2,(c+a)//2,(a+b)//2
        a,b,c=a0,b0,c0
        ans+=1
    print(ans)
A, B, C = map(int, input().split())

if A == B == C:
    print(-1)
else:
    ans = 0
    while A%2 == B%2 == C%2 == 0:
        A, B, C = (B+C)//2, (C+A)//2, (A+B)//2
        ans += 1
    print(ans)
def main():
    A, B, C = map(int, input().split())

    ans = 0
    if (2 * A - B - C) == 0 and (2 * B - A - C) == 0 and (2 * C - A - B) == 0:
        print(-1)
    else:
        for i in range(10**5):
            if A % 2 == 1 or B % 2 == 1 or C % 2 == 1:
                print(ans)
                exit()

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

if __name__ == "__main__":
    main()
import sys
import numpy as np
sys.setrecursionlimit(10 ** 7)

sr = lambda: sys.stdin.readline().rstrip()
ir = lambda: int(sr())
lr = lambda: list(map(int, sr().split()))

cookies = np.array(lr())
if len(set(cookies)) == 1:
    print(-1)
    exit()
if any(cookies&1):
    print(0)
    exit()
count = 0
half_total = cookies.sum() // 2
while True:
    cookies = half_total - cookies//2
    print(cookies)
    count += 1
    if any(cookies&1):
        print(count)
        break
    if count == 10000:
        print(-1)
        exit()
if __name__ == "__main__":
    a, b, c = map(int, input().split())

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

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

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

def main(a,b,c):
  if a == b and b == c:
    return -1
  if a % 2 == 1 or b % 2 == 1 or c % 2 == 1:
      return 0   
  
  cnt = 0
  while True:
    #print(a,b,c)
    a1,b1,c1 = a,b,c
    a = (b1+c1)//2
    b = (a1+c1)//2
    c = (a1+b1)//2
    cnt += 1
    if a % 2 == 1 or b % 2 == 1 or c % 2 == 1:
      return cnt    
    

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

if A == B == C and ((A % 2 != 0) or (B % 2 != 0) or (C % 2 != 0)):
    c = -1
else:
    while (A % 2 == 0) and (B % 2 == 0) and (C % 2 == 0):
        A, B, C = B/2+C/2, C/2+A/2, A/2+B/2
        c += 1

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

def even(a):
	if a % 2 == 0:
		return True
	else:
		return False

cnt = 0
if A == B and B == C:
	cnt = -1

elif not (even(A) and even(B) and even(C)):
		cnt = 0

else:
	cnt = 0
	while even(A) and even(B) and even(C):
		tmp1, tmp2, tmp3 = A,B,C
		A = (tmp2+tmp3) // 2
		B = (tmp3+tmp1) // 2
		C = (tmp1+tmp2) // 2
		cnt += 1

print(cnt)
a,b,c = list(map(int, input().strip().split()))
f=0
if a==b and b==c:
    f=-1
    print(f)
else:
    while a%2==0 and b%2==0 and c%2==0:
        A=a
        B=b
        C=c
        a=B//2+C//2
        b=A//2+C//2
        c=A//2+B//2
        f=f+1
    else:
        print(f)
a,b,c=map(int,input().split())
cnt=0
if a==b==c:
  print(-1)
  exit()
while a%2==b%2==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==b==c:
    print(-1)
elif a%2!=0 or b%2!=0 or c%2!=0:
    print(0)
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 = list(map(int, input().split()))

if A == B == C:
    print(-1)
else:
    c = 0
    while A % 2 == 0 and B % 2 == 0 and C % 2 == 0:
        c += 1
        A2 = (B + C) // 2
        B2 = (A + C) // 2
        C2 = (A + B) // 2

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

if A == B == C or (C+B == 2*A and A+B == 2*C and A+C == 2*B): 
  print(-1)
else:
  c = 0
  while A % 2 == 0 and B % 2 == 0 and C % 2 == 0:
    ba = A
    bb = B
    bc = C
    A = bb//2 + bc//2
    B = ba//2 + bc//2
    C = ba//2 + bb//2
    c+=1
  print(c)
def mapint_inp():
    return map(int, input().split())

A, B, C = mapint_inp()

print(-1)
import sys
a,b,c=map(int,input().split())
ans=0
if a%2==1 or b%2==1 or c%2==1:
    print(-1)
    sys.exit()
if a%2==0 and a==b==c:
    print(-1)
    sys.exit()
while a%2==0 and b%2==0 and c%2==0:
    ta=a/2
    tb=b/2
    tc=c/2
    a=tb+tc
    b=ta+tc
    c=ta+tb
    ans+=1
print(ans)
a,b,c=map(int,input().split())
ans=0
while a%2==0 and b%2==0 and c%2==0:
  d,e,f=0,0,0
  d=(b+c)//2
  e=(a+c)//2
  f=(a+b)//2
  a,b,c=d,e,f
  ans+=1
  if ans==100000:
    break
print(ans)
a, b, c=map(int, input().split())
if a==b and b==c:
  print(-1)
else:
  cnt=0
  while(1):
    if a%2==1 or b%2==1 or c%2==1:
      print(cnt)
      break
    cnt+=1
    ha=a/2
    hb=b/2
    hc=c/2
    a=hb+hc
    b=ha+hc
    c=ha+hb
A,B,C=[int(s) for s in input().split(" ")]

A=[A]
B=[B]
C=[C]

Count=0
for i in range(1000):
    A.append(B[i]/2+C[i]/2)
    B.append(A[i]/2+C[i]/2)
    C.append(B[i]/2+A[i]/2)
    Count+=1
    if A[i+1]%2!=0 or B[i+1]%2!=0 or C[i+1]%2!=0:
        break
    if Count>=1000:
        Count=-1

print(Count)
cookie = list(map(int,input().split()))

if len(set(cookie)) == 1:
  print(-1)
else:
  con = 0
  while True:
    a = cookie[0] // 2
    b = cookie[1] // 2
    c = cookie[2] // 2
    cookie[0] = b + c
    cookie[1] = c + a
    cookie[2] = a + b
    con += 1
    if any([i % 2 != 0 for i in cookie]):
      break

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

flag = 0
ans = 0

if a == b == c:
  ans = -1

else:
  while flag == 0:
    if a%2 == 1 or b%2 == 1 or c%2 == 1:
      flag = 1
      
    else:
      a_tmp = (b+c)/2
      b_tmp = (a+c)/2
      c_tmp = (a+b)/2
      
      a = a_tmp
      b = b_tmp
      c = c_tmp
      
      ans += 1

print(ans)
a, b, c = map(int, input().split())
za = 0
zb = 0
zc = 0

d = 0

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


while a % 2 == 0 and b % 2 == 0 and b % 2 == 0:

    za = a
    zb = b
    zc = c

    a = zb // 2 + zc // 2
    b = za // 2 + zc // 2
    c = za // 2 + zb // 2

    d += 1

print(d)
A, B, C = map(int, input().split())
cnt = 0
flag_cnt=0
while(1):
    A_tmp = A
    B_tmp = B
    C_tmp = C
    A = (B_tmp+C_tmp)/2
    B = (A_tmp+C_tmp)/2
    C = (A_tmp+C_tmp)/2
    cnt += 1
    if A%2!=0 or B%2!=0 or C%2!=0:
        break
    if A_tmp==A and B_tmp==B and C_tmp==C:
        flag_cnt+=1
        if flag_cnt==2:
            cnt = -1
            break
print(cnt)
import sys
input = sys.stdin.readline

def readlines(n):
    for _ in range(n):
        yield map(int, input().split())


def main():
    a, b, c = map(int, input().split())
    if a == b == c:
        yield -1
        return

    while all(x%2 == 0 for x in (a, b, c)):
        a_ = a//2
        b_ = b//2
        c_ = c//2
        a, b, c = b_+c_, a_+c_, a_+b_
        yield 1


print(sum(main()))
a,b,c=map(int,input().split())
if (a==b==c):
  print(-1)
elif (a%2==1 or b%2==1 or c%2==1):
  print(0)
else:
  for i in range(1,10**9):
    a,b,c=(b//2+c//2),(a//2+c//2),(a//2+b//2)
    #print(a,b,c)
    if (a%2==1 or b%2==1 or c%2==1):
      print(i)
      break
a, b, c = map(int,input().split())
ans = 0
l = [a]

while True:
    ans += 1
    x = b//2 + c//2
    y = a//2 + c//2
    z = a//2 + b//2
    if x%2 == 1 or y%2 == 1 or z%2 == 1:
        break
    else:
        a = x
        if a in l:
            print(-1)
            exit()
        else:
            l.append(a)
            b = y
            c = z

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 and b == c:
    break
  else:
    aDummy = a/2
    bDummy = b/2
    cDummy = c/2
    a = (bDummy) + (cDummy)
    b = (aDummy) + (cDummy)
    c = (aDummy) + (bDummy)
    count += 1
print(-1 if a == b and b == c else count)
A,B,C = map(int,input().split())
cou = 0
if(A % 2 == 1 or B % 2 == 1 or C % 2 == 1):
  print("0")
while(cou < 10*7):
  cou += 1
  A = B/2 + C/2
  B = A/2 + C/2
  C = A/2 + B/2
  if(A % 2 == 1 or B % 2 == 1 or C % 2 == 1):
    print(str(cou))
    break
  else:
    pass
print("-1")
A, B, C = map(int, input().split())

cnt = 0
while True:
    if (A == B) & (B == C):
        print(-1)
        exit(0)
    elif (A % 2) | (B % 2) | (C % 2):
        print(cnt)
        exit(0)
    else:
        a, b, c = A // 2, B // 2, C // 2
        A, B, C = b + c, a + c, a + b
        cnt += 1
print(cnt)
import math
import sys

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


while(True):
    cnt += 1
    half_a, half_b, half_c = a / 2, b / 2, c / 2
    ea = half_a % 2 == 0
    eb = half_b % 2 == 0
    ec = half_c % 2 == 0
    if (ea and eb and ec or (not ea) and (not eb) and (not ec)):
        a = half_b + half_c
        b = half_a + half_c
        c = half_a + half_b
    else:
        break

print(cnt)
a,b,c=map(int,input().split())
if a==b==c:
    print(-1)
    exit()
cnt=0
while True:
    x=(b+c)//2
    y=(a+c)//2
    z=(a+b)//2
    a,b,c = x,y,z
    cnt+=1
    if a%2 != 0 or b%2 != 0 or c%2 !=0:
        break
print(cnt)