#include <bits/stdc++.h>
using namespace std;
namespace Dango {
const int MAXN = 200005;
int T, n, ans;
int read() {
  int x = 0, f = 0;
  char ch = getchar();
  while (!isdigit(ch)) {
    f |= (ch == '-');
    ch = getchar();
  }
  while (isdigit(ch)) {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  return f ? -x : x;
}
void solve() {
  priority_queue<int> q;
  n = read();
  ans = 0;
  for (int i = 1; i <= n; i++) {
    int num = read();
    if (!(num & 1)) q.push(num);
  }
  while (!q.empty()) {
    int x = q.top();
    q.pop();
    if (!q.empty() && x == q.top()) continue;
    x /= 2;
    ans++;
    if (x & 1) continue;
    q.push(x);
  }
  printf("%d\n", ans);
}
int work() {
  T = read();
  for (int i = 1; i <= T; i++) solve();
  return 0;
}
}  // namespace Dango
int main() { return Dango::work(); }
