#include <bits/stdc++.h>
using namespace std;
const int N = 200005;
int a[N];
bool cmp(const int& a, const int& b) { return a > b; }
int main() {
  int T;
  cin >> T;
  while (T--) {
    int n;
    cin >> n;
    map<int, int, greater<int> > cnt;
    memset(a, 0, sizeof(a));
    for (int i = 0; i < n; ++i) {
      scanf("%d", &a[i]);
      if ((a[i] & 1) == 0) ++cnt[a[i]];
    }
    int res = 0;
    for (map<int, int, greater<int> >::iterator iter = cnt.begin();
         iter != cnt.end(); ++iter) {
      int firstnum = (*iter).first;
      while ((firstnum & 1) == 0) {
        firstnum >>= 1;
        res++;
        if (cnt.count(firstnum)) {
          cnt[firstnum] += (*iter).second;
          break;
        }
      }
    }
    cout << res << endl;
  }
  return 0;
}
