#include <bits/stdc++.h>
using namespace std;
signed main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long t;
  cin >> t;
  while (t--) {
    long long n;
    cin >> n;
    unordered_map<long long, bool> used;
    priority_queue<long long> kek;
    for (long long i = 0; i < n; i++) {
      long long x;
      cin >> x;
      if (x % 2 == 0 && !used[x]) {
        kek.push(x);
        used[x] = true;
      }
    }
    long long ans = 0;
    while (!kek.empty()) {
      long long bad = kek.top();
      kek.pop();
      if ((bad / 2) % 2 == 0 && !used[bad / 2]) {
        kek.push(bad / 2);
      }
      ans++;
    }
    cout << ans << "\n";
  }
  return 0;
}
