#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    int arr[n];
    for (int i = 0; i < n; i++) {
      cin >> arr[i];
    }
    set<int> s;
    for (int i = 0; i < n; i++) {
      s.insert(arr[i]);
    }
    int count = 0;
    while (s.empty() == false) {
      int m = *(s.rbegin());
      s.erase(m);
      if (m % 2 == 0) {
        m = m / 2;
        s.insert(m);
        count++;
      }
    }
    cout << count << endl;
  }
}
