peterverebics/CodeNet_Python_118 huggingface dataset:
A,B,C = map(int, input().split())
a = [A]
b = [B]
c = [C]
count = 0
for i in range(10 ** 9 + 1):
 
    if a[i] == b[i] == c[i]:
        count = -1
        break
    elif a[i] % 2 == 1 or b[i] % 2 == 1 or c[i] % 2 == 1:
        break
    else:
        a.append(b[i] / 2 + c[i] / 2)
        b.append(a[i] / 2 + c[i] / 2)
        c.append(a[i] / 2 + b[i] / 2)
        count += 1

print(count)
a,b,c=list(map(int,input().split()))
if a==b and b==c and c==a:
  print('-1')
n=0
while a%2==0 and b%2==0 and c%2==0:
  temp_a = c/2+b/2
  temp_b = a/2+c/2
  temp_c = a/2+b/2
  a = temp_a
  b = temp_b
  c = temp_c
  n+=1
print(n)
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 == B == C:
  ans = -1
print(ans)
A,B,C=map(int, input().split())
cnt=0
while True:
  A=A//2
  B=B//2
  C=C//2
  flgA=A%2==0
  flgB=B%2==0
  flgC=C%2==0
  Aa=B+C
  Bb=A+C
  Cc=A+B
  A=Aa
  B=Bb
  C=Cc

  cnt+=1
  if A==B and A==C:
    print(-1)
    exit(0)
  if [flgA, flgB, flgC].count(True) !=3:
    break

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

total = a + b + c

if a % 2 == 0 and b % 2 == 0 and c % 2 == 0 and a == b == c:
    print(-1)
else:
    count = 1
    while True:
        a, b = (total - a) / 2, (total - b) / 2
        if a % 2 != 0 or b % 2 != 0:
            print(count)
            break
        else:
            count += 1
def 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:
        ans += 1
        A, B, C = (B + C) * 0.5, (A + C) * 0.5, (A + B) * 0.5
    print(ans)


if __name__ == '__main__':
    main()
a, b, c=map(int,input().split())
A,B,C = a,b,c
ans = 0
if(a%2 or b%2 or c%2): ans = -1
while(a%2==0 and b%2==0 and c%2==0):
  if(A==B==C):
    ans = 0
    break
  A,B,C = a,b,c
  a = B//2 + C//2
  b = A//2 + C//2
  c = A//2 + B//2
  ans += 1
print(ans) if(ans>=0) else print(-1)
# おっぱっぴー

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

if A == B == C:
    print(-1)
else:
    for i in range(100):
        if A % 2 != 0 or B % 2 != 0 or C % 2 != 0:
            print(i)
            break
        A, B, C = B//2+C//2, A//2+C//2, A//2+B//2
a,b,c = tuple(map(int,input().split()))

ans = 0
while True:
  if len(set((a,b,c)))<3:
    print(-1)
    exit()
  if 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
    ans+=1
  else:
    break
print(ans)
a,b,c=map(int,input().split())
if a==b==c:
  print(-1)
  exit(0)
ans=0
while a%2==0 and b%2==0 and c%2==0:
  aa=a/2
  bb=b/2
  cc=c/2
  a=bb+cc
  b=aa+cc
  c=bb+aa
  ans+=1
print(ans)
a, b, c = map(int, input().split())

count = 0

if a == b == c:
    print(-1)
else: 
    for _ in range(100000):
        
        _a, _am = divmod(a, 2)
        _b, _bm = divmod(b, 2)
        _c, _cm = divmod(c, 2)

        if _am or _bm or _cm:
            print(count)
            break
        else:
            a = _b + _c
            b = _a + _c
            c = _a + _b
            count += 1
import bisect,collections,copy,itertools,math,numpy,string
def I(): return int(input())
def S(): return input()
def LI(): return list(map(int,input().split()))
def LS(): return list(input().split())
##################################################
A,B,C = LI()
ans = 0
if A==B==C:
    ans = -1
else:
    while 1:
        if A%2 or B%2 or C%2:
            break
        A,B,C = (B+C)//2,(A+C)//2,(A+B)//2
        ans += 1
print(ans)
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+C)//2
        y = (A+C)//2
        z = (A+B)//2
        A = x
        B = y
        C = z
        cnt += 1
    print(cnt)
A, B, C = list(map(int, input().split()))

if A == B == C:
    if A % 2 == 0:
        print('-1')
else:
    count = 0
    for _ in range(10 ** 9):
        if A % 2 != 0 or B % 2 != 0 or C % 2 != 0:
            print(count)
            break
        tmp_A = A
        tmp_B = B
        tmp_C = C
        A = (tmp_B + tmp_C) / 2
        B = (tmp_A + tmp_C) / 2
        C = (tmp_B + tmp_A) / 2
        count += 1
A, B, C = map(int, input().split())

cnt = 0
if(A==B==C):
    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,b,c=map(int,input().split())
f=True
aa=0
bb=0
cc=0
cnt=0
while f:
	aa = b/2+c/2
	bb = a/2+c/2
	cc = a/2+b/2
	cnt+=1
	if aa == bb == cc:
		cnt=-1
		break
	if aa%2!=0 or bb%2!=0 or cc%2!=0:
		f=False
	else:
		a=aa
		b=bb
		c=cc
	
print(cnt)
def resolve():
    a,b,c=map(int, input().split())
    if a+b==a+c==b+c:
        print(-1)
    else:
        cnt=0
        while a%2==b%2==c%2==0:
            a_new=(b+c)//2
            b_new=(a+c)//2
            c_new=(a+b)//2
            a=a_new
            b=b_new
            c=c_new
            cnt+=1
        print(cnt)

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

flag = 0
ans = 0

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

else:
  while flag == 0:
    if a%2 == 0 and b%2 == 0 and c%2 == 0:
      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
      
    else:
      flag = 1

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

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

count = 0
while all([a % 2 == 0, b % 2 == 0, c % 2 == 0]):
    a, b, c = (b + c) // 2, (a + c) // 2, (a + b) // 2
    count += 1

print(count)
import sys
sys.setrecursionlimit(10**9)

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

if a == b == c:
	print(-1)
	sys.exit()
cnt = 0
while True:
	if a%2==1 or b%2==1 or c%2==1:
		break
	a,b,c = (b+c)//2,(a+c)//2,(b+c)//2
	cnt += 1

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

ans = 0
for i in range(10000):
    if a == b == c:
        print(-1)
        break
    if (a + 1) * (b + 1) * (c + 1) % 2 == 0:
        print(ans)
        break
    ans += 1
    a, b, c = a // 2, b // 2, c // 2
    a, b, c = b + c, a + c, b + c
a, b, c =map(int, input().split())
i,j,k = a,b,c
X=0
if a ==b and b ==c:
  print('-1')
  exit()
else:
  while i%2 ==0 and j%2==0 and k%2==0:
    i = (b+c)/2
    j = (c+a)/2
    k = (a+b)/2
    a,b,c = i,j,k
    X +=1
print(X)
a, b, c = map(int, input().split())
a_tmp = a ; b_tmp = b ; c_tmp = c
count = 0
while True :
    if a == b == c :
        print("-1")
        break
    elif a%2 == 1 or b%2 == 1 or c%2 == 1 :
        print(count)
        break
    else :
        a = b_tmp/2 + c_tmp/2
        b = a_tmp/2 + c_tmp/2
        c = a_tmp/2 + b_tmp/2
        a_tmp = a ; b_tmp = b ; c_tmp = c
        count += 1
a, b, c = map(int, input().split())
count = 0
for i in range(10**7):
    a, b, c = b/2 + c/2, a/2 + c/2, a/2 + b/2
    count += 1
    if a%2 != 0 or b%2 != 0 or c%2 != 0:
        print(count)
        exit()
print(-1)
A,B,C=map(int, input().split())
if A==B and B==C:
  print(-1)
  exit(0)

cnt=0
while True:
  A=A//2
  B=B//2
  C=C//2
  flgA=A%2==0
  flgB=B%2==0
  flgC=C%2==0
  Aa=B+C
  Bb=A+C
  Cc=A+B
  A=Aa
  B=Bb
  C=Cc

  cnt+=1
  if [flgA, flgB, flgC].count(True) !=3:
    break

print(cnt)
A, B, C = map(int, input().split())
if A != B != C:
  D = 0
  while A%2 == 0 and B%2 == 0 and C%2 == 0:
    A = B/2 + C/2
    B = A/2 + C/2
    C = A/2 + B/2
    D += 1
  print(D)
else:
  print('-1')
import numpy as np
import sys

input = sys.stdin.readline

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

ans = 0

if A == B and  B == C:
    ans = -1
else:
    while A%2 == 0 and B%2 == 0 and C%2 == 0:
        next_a =int( C/2 + B/2)
        next_b =int( A/2 + C/2)
        next_c =int( A/2 + B/2)
        A = next_a
        B = next_b
        C = next_c
        ans += 1
        if A == B and B == C:
            ans = -1


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

if A == B and B == C:
    print('-1')
    sys.exit()
count = 0
while True:
    a = B//2 + C//2
    b = C//2 + A//2
    c = A//2 + B//2
    count += 1
    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())
if a ==b and b ==c:
  print('-1')
  exit()
X = 0
i,j,k = a,b,c
while i%2 ==0 and j%2==0 and k%2==0:
  i = (b+c)/2
  j = (c+a)/2
  k = (a+b)/2
  a,b,c = i,j,k
  X +=1
print(X)
a,b,c = map(int,input().split())
count = 0
if a == b == c :
  print(-1)
else:
  while a%2 == 0 or b%2 == 0 or c%2 == 0:
    a1 = a
    b1 = b
    c1 = c
    a = a1//2 + b1//2 + c1//2
    b = a1//2 + b1//2 + c1//2
    c = a1//2 + b1//2 + c1//2
    count += 1
  print(count)
import sys

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

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

count = 0
while True:
    a = (A+B)/2
    b = (C+A)/2
    c = (A+B)/2
    count += 1
    if (a == b and b == c) or count > 31:
        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)
from fractions import gcd
def main():
    a, b, c = map( int, input().split())
    if a == b == c:
        print("-1")
        return
    ans = 0
    bi = 2
    while a%bi == 0 and b%bi == 0 and c%bi == 0:
        a, b, c = a//2+b//2, b//2+c//2, c//2+a//2
        ans += 1
    print(ans)
if __name__ == '__main__':
    main()
a, b, c = map(int, input().split())
 
if a == b == c:
    print(-1)
    exit()

if a % 2 != 0 or b % 2 != 0 or c % 2 != 0:
    print(0)    
    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 - Cookie Exchanges

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

def div2(x):
    ans = 0
    while(x%2==0):
        x /= 2
        ans += 1
    return ans

if A==B and B==C:
    print(-1)
else:
    print(min(div2(abs(A-B)), div2(abs(A-C))))
a,b,c=map(int,input().split())
e=a-b|c-b
print(len(bin(e&-e))-3or~a%-2)
A,B,C = map(int,input().split())
ans = 0
if A == B == C:
  ans = -1
else:
  while A%2 == 0 and B%2 == 0 and C%2 == 0:
    if A == B == C:
      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())

#print(A,B,C)

if 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)
def resolve():
    A,B,C = map(int,input().split())
    count = 0
    if A == C and A == B and A % 2 == 1:
        print(-1)
    else:
        while (A % 2 == 0 and B % 2 == 0 and C % 2 == 0):
            tmpA = (B + C) / 2 
            tmpB = (A + C) / 2 
            tmpC = (A + B) / 2
            A = tmpA
            B = tmpB
            C = tmpC
            count = count + 1
        print(count)
resolve()
a,b,c = map(int,input().split())
count = 0
if a == b == c :
  print(-1)
else:
  while a%2 == 0 or b%2 == 0 or c%2 == 0:
    count += 1
    a1 = a
    b1 = b
    c1 = c
    a = a1//2 + b1//2 + c1//2
    b = a1//2 + b1//2 + c1//2
    c = a1//2 + b1//2 + c1//2
  print(count)
a, b, c = map(int, input().split())
a_tmp = a ; b_tmp = b ; c_tmp = c
count = 0
while True :
    count += 1
    a = b_tmp/2 + c_tmp/2
    b = a_tmp/2 + c_tmp/2
    c = a_tmp/2 + b_tmp/2
    a_tmp = a ; b_tmp = b ; c_tmp = c
    if a%2 == 1 or b%2 == 1 or c%2 == 1 :
        print(count)
        break
    elif count > 100000 :
        print("-1")
        break
    else :
        continue
a,b,c = map(int,input().split())
i = 0

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

while a % 2 == 0 and b % 2 == 0 and c % 2 == 0:
    al = b // 2 + c // 2
    bl = a // 2 + c // 2
    cl = a // 2 + b // 2
    a = al
    b = bl
    c = cl
    i += 1

print(i)
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 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())

count = 0

if a == b == c:
    print(-1)
else: 
    for _ in range(10000):
        
        _a, _am = divmod(a, 2)
        _b, _bm = divmod(b, 2)
        _c, _cm = divmod(c, 2)

        if _am or _bm or _cm:
            print(count)
            break
        else:
            a = _b + _c
            b = _a + _c
            c = _a + _b
            count += 1
a, b, c = map(int, input().split())
za = a
zb = b
zc = c

d = 0

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

while True:
    a = int(zb / 2) + int(zc / 2)
    b = int(za / 2) + int(zc / 2)
    c = int(za / 2) + int(zb / 2)

    za = a
    zb = b
    zc = c

    d += 1
    
    if a % 2 != 0 or b % 2 != 0 or b % 2 != 0:
        print(d)
        exit()
A,B,C=map(int,input().split())
count=0
if A==B and A==C:
  print("-1")
  exit()
while True:
  if A%2==1 or B%2==1 or C%2==1:
    break
  a,b,c=A/2,B/2,C/2
  A,B,C=b+c,a+c,a+b
  count+=1
print(count)
a, b, c = list(map(int, input().split()))

cnt = 0
if (a == b) and (b == c) and (a%2==0):
    print(-1)
else:
    while(True):
        a_ = a/2
        b_ = b/2
        c_ = c/2
        a = b_ + c_
        b = a_ + c_
        c = a_ + b_
        cnt+=1
        if a%2!=0 or b%2!=0 or c%2!=0:
            print(cnt)
            exit()
a,b,c=map(int,input().split())
if a==b==c:
    print(-1)
else:
    ans=0
    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=B//2+A//2
        ans+=1
        if a==b==c:
            ans=-1
            break
    print(ans)
import sys
input = sys.stdin.readline


def readstr():
    return input().strip()


def readint():
    return int(input())


def readnums():
    return map(int, input().split())


def readstrs():
    return input().split()


def main():
    A, B, C = readnums()
    if A == B and B == C:
        print(-1)
    else:
        ans = 0
        while all([not A % 2, not B % 2, not C % 2]):
            A, B, C = (B + C) // 2, (A + C) // 2, (A + B) // 2
            ans += 1

        print(ans)


if __name__ == "__main__":
    main()
a,b,c=map(int,input().split())
na = nb = nc = 0
cnt = 0
if a == b == c:
    print(-1)
else:
    while a%2==0 and b%2==0 and c%2==0:
        na = (b+c)//2
        nb = (c+a)//2
        nc = (a+b)//2
        cnt += 1
        a,b,c = na,nb,nc
    print(cnt)
a,b,c = map(int,input().split())
ans = 0
if a == b == c and a%2 == 0:
    print(-1,-1,-1)
    exit()
while a%2 == b%2 == c%2 == 0:
    x,y,z = a//2, b//2, c//2
    a = y + z
    b = x + z
    c = x + y
    ans += 1
print(ans)
a,b,c=map(int,input().split())
if a==b==c:
  print(-1)
  exit()
cnt=0
while all([q%2==0 for q in (a,b,c)]):
  cnt+=1
  s=a+b+c
  a=s-a
  a//=2
  b=s-b
  b//=2
  c=s-c
  c//=2
print(cnt)
#13
a,b,c = map(int,input().split())
cnt = 0
while a%2 == b%2 == c%2 == 0:
    if a==b==c:
        print('-1')
        break
    else:
        a,b,c = b//2+c//2,c//2+a//2,a//2+b//2
        cnt+=1
        print(a,b,c)

print(cnt)
import sys

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


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

cnt = 0
while A % 2 == 0 and B % 2 == 0 and C % 2 == 0:
    a = B // 2 + C // 2
    b = A // 2 + C // 2
    c = A // 2 + B // 2
    A = a
    B = b
    C = c
    cnt += 1
print(cnt)
def main():
    a=tuple(map(int,input().split()))
    e=set()
    count = 0
    while a not in e:
        e.add(a)
        count += 1
        a=((a[1]+a[2])//2,(a[0]+a[2])//2,(a[0]+a[1])//2)
        for x in a:
            if x % 2 != 0:
                print(count)
                return
    else:
        print(-1)
    
if __name__ == "__main__":
    main()
def main():
    a, b, c = map(int, input().split())

    count = 0
    while True:
        count += 1
        i, j, k = a / 2, b / 2, c / 2
        a, b, c = j + k, k + i, i + j

        if a % 2 == 1 or b % 2 == 1 or c % 2 == 1:
            print(count)
            break
        elif a == b == c:
            print(-1)
            break


if __name__ == '__main__':
    main()
a,b,c=map(int,input().split())

if a%2==1 or b%2==1 or c%2==1:
  print(0)
elif a==b==c:
  print(-1)
else:
  cnt=0
  d=a
  e=b
  f=c
  while d%2==0 and e%2==0 and f%2==0:
    d=(e+f)/2
    e=(f+d)/2
    f=(d+e)/2
    cnt+=1 
  print(cnt)
a, b, c = map(int, input().split())

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

if a % 2 != 0 or b % 2 != 0 or c % 2 != 0:
    print(0)
    exit()

cnt = 1
while cnt:
    a, b, c = int((b+c)/2), int((a+c)/2), int((a+b)/2)
    
    if a % 2 != 0 or \
       b % 2 != 0 or \
       c % 2 != 0: break
    cnt += 1

print(cnt)
a,b,c=map(int,input().split())
if a==b and b==c:
    ans=-1
for i in range(1,1000000000):
    x=a//2
    y=b//2
    z=c//2
    a=y+z
    b=x+z
    c=x+y
    if a%2==1 or b%2==1 or c%2==1:
        ans=i
        break
print(ans)
a,b,c = map(int,input().split())
if a == b == c:
    print(-1)
    exit()
for i in range(10**8):
    if a%2 != 0 or b%2 != 0 or c%2 != 0:
        break
    a_o,b_o,c_o = a,b,c
    a = b_o//2 + c_o//2
    b = a_o//2 + c_o//2
    c = a_o//2 + b_o//2
print(i)
a,b,c = map(int,input().split(" "))
n = 0
if a == b == c:
  print(-1)
  exit()
if a % 2 == 1:
    print(0)
    exit()
if b % 2 == 1:
    print(0)
    exit()
if c % 2 == 1:
    print(0)
    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 = 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:
        aa, bb, cc = a, b, c
        a = bb // 2 + cc // 2
        b = aa // 2 + cc // 2
        c = aa // 2 + bb // 2
        ans += 1
    print(ans)
A,B,C = map(int, input().split())
a = [A]
b = [B]
c = [C]
count = 0
for i in range(10 ** 9):
 
    if a[i] == b[i] == c[i]:
        count = -1
        break
    elif a[i] % 2 == 1 or b[i] % 1 == 0 or c[i] % 2 == 1:
        break
    else:
        a.append(b[i] / 2 + c[i] / 2)
        b.append(a[i] / 2 + c[i] / 2)
        c.append(a[i] / 2 + b[i] / 2)
        count += 1

print(count)
A,B,C=[int(s) for s in input().split(" ")]

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

Count=0
for i in range(1000000000):
    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>=100000:
        Count=-1
        break

print(Count)
a,b,c=map(int,input().split())
e=a-b|b-c
print((e!=0)*(e^e-1).bit_length()-1)
ans = 0
A, B, C = map(int, input().split())
if A == B and A == C:
    print(-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
        ans += 1
    print(ans)
A,B,C =map(int,input().split())
con = 0
if A == B and B == C:
  print(-1)
  exit()
while True:
  if A % 2 == 1 or B % 2 == 1 or C % 2 == 1:
    break
  con += 1
  D = A / 2
  E = B / 2
  F = C / 2
  A = E + F
  B = D + F
  C = D + E
  
print(con)
def main():
  A,B,C = map(int,input().split())
  s = [A,B,C]
  a,b,c = A,B,C
  if a == b and b == c:
    return -1

  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
    cnt += 1
    #print(a,b,c)
    if [a,b,c] == s:
      return -1
    
  return cnt    
    

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

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

if a % 2 != 0 or b % 2 != 0 or c % 2 != 0:
    print(0)
    exit()

cnt = 1
while cnt:
    a, b, c = (b+c)/2, (a+c)/2, (a+b)/2
    
    if a % 2 != 0 or \
       b % 2 != 0 or \
       c % 2 != 0: break
    cnt += 1

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

if A == B == C:
  print(-1)
else:
  c = 0
  while A % 2 == 1 or B % 2 == 1 or C % 2 == 1:
    A = B//2 + C//2
    B = A//2 + C//2
    C = B//2 + C//2
    c+=1
  print(c)
# おっぱっぴー

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

if A == B == C:
    print(-1)
for i in range(100):
    if A % 2 != 0 or B % 2 != 0 or C % 2 != 0:
        print(i)
        break
    A, B, C = B/2+C/2, A/2+C/2, A/2+B/2
A, B, C = map(int, input().split())

if A==B==C:
    print(-1)
else:
    for i in range(100000000):
        if A %2==0 and B%2==0 and C%2==0:
            a = A/2
            b = B/2
            c = C/2
            A = b+c
            B = a+c
            C = a+b
        else:
            print(i)
            exit()
import sys
A,B,C = map(int,input().split())
result = 0
if A == B and B == C:
  print(-1)
  sys.exit()
else:
  while A % 2 == B % 2 and B % 2 == C % 2 and C % 2 == 0:
    a = (B + C) // 2
    b = (C + A) // 2
    c = (A + B) // 2
    A,B,C = a,b,c
    result += 1
print(result)
a,b,c=map(int,input().split())

if a==b==c and a%2==0:
    print(-1)
else:
    num=0
    while True:
        if a%2==1 or b%2==1 or c%2==1:
            break
        else:
            num+=1
            l0=(b+c)/2
            l1=(c+a)/2
            l2=(a+b)/2
            a,b,c=l0,l1,l2
    else:
        print(num)
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:
    num_a,num_b,num_c=a/2,b/2,c/2
    a=num_b+num_c
    b=num_a+num_c
    c=num_a+num_b
    ans+=1
  
print(ans)
a,b,c=map(int,input().split())
count=0
if a==b==c:
    print(-1)
    exit()
while a%2==0 and b%2==0 and c%2==0:
    A=a//2
    B=b//2
    C=c//2
    a=B+C
    b=C+A
    c=A+B
    count+=1
    if a==b==c:
        print(-1)
        exit()
print(count)
import numpy as np
cookies = np.array([int(x) for x in input().split()])

if cookies[0] == cookies[1] == cookies[2]:
  ans = -1
else:
  ans = 0
  while True:
    if not any(cookies%2):
      cookies = cookies//2
      ans += 1
      continue
    if all(cookies%2):
      ans += 1
    break
print(ans)
A,B,C = map(int,input().split())
cnt = 0
while True:
    if A == B == C:
        print(-1)
        break
    if A % 2 == 1 or B % 2 == 1 or C % 2 == 1:
        print(cnt)
        break
    else:
        a = A
        b = B
        c = C
        A = (b+c)//2
        B = (a+c)//2
        C = (a+b)//2
        cnt +=1
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:
    if a%2 == 1 or b%2 == 1 or c%2 == 1:
      flag = 1
      
    else:
      a_tmp = b/2+c/2
      b_tmp = a/2+c/2
      c_tmp = a/2+b/2
      
      a = a_tmp
      b = b_tmp
      c = c_tmp
      
      ans += 1

print(ans)
a, b, c = map(int, input().split())
count = 0
for i in range(10**9+1):
    a, b, c = b/2 + c/2, a/2 + c/2, a/2 + b/2
    count += 1
    if a%2 != 0 or b%2 != 0 or c%2 != 0:
        print(count)
        exit()
print(-1)
a,b,c = map(int,input().split())
cnt=0
for i in range(100):
    if a==b==c and a%2==0:
        cnt = -1
        break
    elif a%2==0 and b%2==0 and c%2==10:
        t_a = b//2 + c//2
        t_b = a//2 + c//2
        t_c = a//2 + b//2
        a,b,c = t_a,t_b,t_c
        cnt+=1
    else:
        break
print(cnt)
a,b,c=map(int,input().split())
if a==b==c:
    print(-1)
else:
    while True:
        total=0
        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