#include <bits/stdc++.h>
using namespace std;
void faster() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
}
long long q, n, s, k, ans, sum, x, h, a[456789], b;
set<int> second;
void dii() {
  cin >> n;
  second.clear();
  ans = 0;
  for (int i = 1; i <= n; i++) {
    cin >> x;
    second.insert(x);
  }
  while (!second.empty()) {
    k = *second.rbegin();
    second.erase(k);
    if (k % 2 == 0) {
      ans++;
      second.insert(k / 2);
    }
  }
  cout << ans;
  cout << endl;
}
int main() {
  faster();
  q = 1;
  cin >> q;
  while (q--) {
    dii();
  }
  return 0;
}
