import java.util.*;
public class Main {

		static void solve() {
			Scanner sc = new Scanner(System.in);
			int n = sc.nextInt();
			int[] array = new int [n];
			int ans = 0;
			for(int i = 0;i<n;i++) {
				array[i] = sc.nextInt();
			}
			sc.close();
			for(int j = 0;j<n+1;j++) {
			for(int i = 0;i<n;i++) {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			}
		}
			System.out.println(ans);
		}
	
	public static void main(String[] args) {
		solve();
	}

} import java.util.*; util.* java public class Main {

		static void solve() {
			Scanner sc = new Scanner(System.in);
			int n = sc.nextInt();
			int[] array = new int [n];
			int ans = 0;
			for(int i = 0;i<n;i++) {
				array[i] = sc.nextInt();
			}
			sc.close();
			for(int j = 0;j<n+1;j++) {
			for(int i = 0;i<n;i++) {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			}
		}
			System.out.println(ans);
		}
	
	public static void main(String[] args) {
		solve();
	}

} Main static void solve() {
			Scanner sc = new Scanner(System.in);
			int n = sc.nextInt();
			int[] array = new int [n];
			int ans = 0;
			for(int i = 0;i<n;i++) {
				array[i] = sc.nextInt();
			}
			sc.close();
			for(int j = 0;j<n+1;j++) {
			for(int i = 0;i<n;i++) {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			}
		}
			System.out.println(ans);
		} solve {
			Scanner sc = new Scanner(System.in);
			int n = sc.nextInt();
			int[] array = new int [n];
			int ans = 0;
			for(int i = 0;i<n;i++) {
				array[i] = sc.nextInt();
			}
			sc.close();
			for(int j = 0;j<n+1;j++) {
			for(int i = 0;i<n;i++) {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			}
		}
			System.out.println(ans);
		} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int[] array = new int [n]; array new int [n] n int ans = 0; ans 0 for(int i = 0;i<n;i++) {
				array[i] = sc.nextInt();
			} int i = 0; int i = 0; i 0 i<n i n i++ i++ i {
				array[i] = sc.nextInt();
			} {
				array[i] = sc.nextInt();
			} array[i] = sc.nextInt() array[i] array i sc.nextInt() sc.nextInt sc sc.close() sc.close sc for(int j = 0;j<n+1;j++) {
			for(int i = 0;i<n;i++) {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			}
		} int j = 0; int j = 0; j 0 j<n+1 j n+1 n 1 j++ j++ j {
			for(int i = 0;i<n;i++) {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			}
		} {
			for(int i = 0;i<n;i++) {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			}
		} for(int i = 0;i<n;i++) {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			} int i = 0; int i = 0; i 0 i<n i n i++ i++ i {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			} {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			} if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				} array[i]%2==0 && array[i] !=2 array[i]%2==0 array[i]%2 array[i] array i 2 0 array[i] !=2 array[i] array i 2 {
					array[i]/=2;
					ans++;
				} array[i]/=2 array[i] array i 2 ans++ ans {
					array[i]*=3; 
				} array[i]*=3 array[i] array i 3 System.out.println(ans) System.out.println System.out System System.out ans public static void main(String[] args) {
		solve();
	} main {
		solve();
	} solve() solve String[] args args public class Main {

		static void solve() {
			Scanner sc = new Scanner(System.in);
			int n = sc.nextInt();
			int[] array = new int [n];
			int ans = 0;
			for(int i = 0;i<n;i++) {
				array[i] = sc.nextInt();
			}
			sc.close();
			for(int j = 0;j<n+1;j++) {
			for(int i = 0;i<n;i++) {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			}
		}
			System.out.println(ans);
		}
	
	public static void main(String[] args) {
		solve();
	}

} public class Main {

		static void solve() {
			Scanner sc = new Scanner(System.in);
			int n = sc.nextInt();
			int[] array = new int [n];
			int ans = 0;
			for(int i = 0;i<n;i++) {
				array[i] = sc.nextInt();
			}
			sc.close();
			for(int j = 0;j<n+1;j++) {
			for(int i = 0;i<n;i++) {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			}
		}
			System.out.println(ans);
		}
	
	public static void main(String[] args) {
		solve();
	}

} Main
import java.util.*;
public class Main {

		static void solve() {
			Scanner sc = new Scanner(System.in);
			int n = sc.nextInt();
			int[] array = new int [n];
			int ans = 0;
			for(int i = 0;i<n;i++) {
				array[i] = sc.nextInt();
			}
			sc.close();
			for(int j = 0;j<n+1;j++) {
			for(int i = 0;i<n;i++) {
				if(array[i]%2==0 && array[i] !=2) {
					array[i]/=2;
					ans++;
				}
				else {
					array[i]*=3; 
				}
			}
		}
			System.out.println(ans);
		}
	
	public static void main(String[] args) {
		solve();
	}

}