#include <cstdio>
#include <iostream>
using namespace std;
int main() {
int n, cnt = 0;
scanf("%d",&n);
while(1) {
if(n % 2 != 0) { //奇数
n = (3 * n + 1) / 2;
} else { //偶数
n /= 2;
}
cnt++;
if(n == 1) {
printf("%d",cnt);
return 0;
}
}
return 0;
}