#include <bits/stdc++.h>
using namespace std;
int t;
int n;
int a[200007];
int ans;
map<int, int> count1;
int c, m, store;
void solve(int x, int ind) {
  c = 0;
  store = x;
  while (x % 2 == 0) {
    x /= 2;
    if (x % 2 == 0) count1[x] = -1;
    c++;
  }
  count1[store] = c;
}
int main() {
  cin >> t;
  while (t--) {
    ans = 0;
    cin >> n;
    memset((a), 0, sizeof((a)));
    count1.clear();
    for (int i = 0; i < (n); ++i) {
      cin >> a[i];
      if (a[i] % 2 == 0 and count1[a[i]] != -1) {
        m = a[i];
        solve(m, i);
      }
    }
    for (int i = 0; i < (n); ++i) {
      if (count1[a[i]] >= 1) {
        ans += count1[a[i]];
        count1[a[i]] = 0;
      }
    }
    cout << ans << endl;
  }
}
