#include<bits/stdc++.h>
using namespace std;
#define ll long long
int main(){
  ll a,b,c;
  int cnt=0;
  cin>>a>>b>>c;
  for(int i=0;i<100000;i++){
    if(a%2==1||b%2==1||c%2==1){
      cout<<cnt<<endl;
      return(0);
    }
    ll na=b/2+c/2;
    ll nb=a/2+c/2;
    ll nc=a/2+b/2;
    a=na;
    b=nb;
    c=nc;
    cnt++;
  }
  cout<<-1<<endl;
  return(0);
}
