#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  for (int i = 1; i <= t; i++) {
    int n;
    cin >> n;
    map<int, int> a;
    int s = 0;
    for (int j = 0; j < n; j++) {
      int tmp;
      cin >> tmp;
      if (tmp % 2 == 1) continue;
      int c = 0;
      while (tmp % 2 == 0) {
        c++;
        tmp /= 2;
      }
      a[tmp] = max(c, a[tmp]);
    }
    for (auto it = a.begin(); it != a.end(); it++) {
      s += it->second;
    }
    cout << s << endl;
  }
}
