#include <bits/stdc++.h>
using namespace std;
int main() {
  set<int, greater<int> > s;
  int i, x, n, t;
  cin >> t;
  while (t--) {
    vector<int> v;
    cin >> n;
    for (i = 0; i < n; i++) {
      cin >> x;
      v.push_back(x);
      if (v[i] % 2 == 0) s.insert(v[i]);
    }
    int c = 0;
    set<int, greater<int> >::iterator it;
    for (it = s.begin(); it != s.end(); it++) {
      if (*it % 2 == 0) {
        x = *it / 2;
        s.insert(x);
        c++;
      }
    }
    s.clear();
    cout << c << "\n";
  }
  return 0;
}
