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

if a==b==c:

  print((-(a%2<1)))

else:

  s=0

  while a%2<1and b%2<1and c%2<1:

    a,b,c=(b+c)//2,(c+a)//2,(a+b)//2

    s+=1

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

e=a-b|b-c

print(((e!=b%2)*(e^e-1).bit_length()-1))
a, b, c = list(map(int, input().split()))
if a == b == c:
    print((-(a % 2 < 1)))
else:
    s = 0
    while a % 2 < 1 and b % 2 < 1 and c % 2 < 1:
        a, b, c = (b + c) // 2, (c + a) // 2, (a + b) // 2
        s += 1
    print(s)

a, b, c = list(map(int, input().split()))
e = a - b | b - c
print(((e != b % 2) * (e ^ e - 1).bit_length() - 1))

-if a == b == c: -    print((-(a % 2 < 1))) -else: -    s = 0 -    while a % 2 < 1 and b % 2 < 1 and c % 2 < 1: -        a, b, c = (b + c) // 2, (c + a) // 2, (a + b) // 2 -        s += 1 -    print(s) +e = a - b | b - c +print(((e != b % 2) * (e ^ e - 1).bit_length() - 1))