#pragma GCC optimize("Ofast,no-stack-protector")
#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,avx2")
#pragma GCC optimize("unroll-loops")
#pragma GCC optimize("fast-math")

#include <algorithm>
#include <bitset>
#include <cassert>
#include <chrono>
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <ctime>
#include <deque>
#include <iomanip>
#include <iostream>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <random>
#include <set>
#include <string>
#include <time.h>
#include <unordered_map>
#include <unordered_set>
#include <vector>

#define pb push_back
#define empb emplace_back
#define mp make_pair
#define mtp make_tuple
#define umap unordered_map
#define uset unordered_set
#define sqr(a) ((a) * (a))
#define all(x) (x).begin(), (x).end()
#define rall(x) (x).rbegin(), (x).rend()
#define rev(v) reverse(v.begin(), v.end());
#define fastio() ios_base::sync_with_stdio(0); cout.tie(0); cin.tie(0); srand((ui)time(NULL))

#define endl '\n'

using namespace std;

typedef long long ll;
typedef long double ld;
typedef unsigned long long ull;
typedef unsigned int ui;

const ld eps = 1e-9;
const ld PI = acos(-1);
const ll infll = 1e18 + 1329;
const int inf = 1e9 + 1329;
const ld E = 2.71828182845904523536028747135266249775724709369995;
vector<ll> mods = {1000065757, 1000570057, 1004571329, 1000580179, 1000057769, 1000001329, 1000006957, 1000056157, 1001001329};
vector<ll> hashpows = {29, 31, 37, 43, 47, 53, 59, 157, 179, 257};
mt19937 rnd((ui) chrono::high_resolution_clock::now().time_since_epoch().count() + (ui) 1329);
ll hashmod = mods[rnd() % mods.size()];
ll hashpow = hashpows[rnd() % hashpows.size()];
#define int ll

template <class T>
istream& operator>> (istream& stream, vector<T>& v) { for(int i = 0; i < v.size(); ++i) { stream >> v[i]; } return stream; }
template <class T>
ostream& operator<< (ostream& stream, vector<T>& v) { for(int i = 0; i < v.size(); ++i) { stream << v[i] << " "; } stream << '\n'; return stream; }

signed main() {
    //fastio();
    int t; cin >> t;
    while (t--) {
        int n; cin >> n;
        vector<int> v (n);
        for (int i = 0; i < n; ++i) cin >> v[i];
        vector<int> o, e;
        for (int i = 0; i < n; ++i) {
            if (v[i] % 2 == 0) {
                e.push_back(v[i]);
            } else {
                o.push_back(v[i]);
            }
        }
        sort(all(o)); sort(all(e));
        int a = 0, b = 0;
        for (int i = 0; i < n; ++i) {
            if (i % 2 == 0) {
                if (o.empty() || (!e.empty() && e.back() > o.back())) {
                    a += e.back();
                    e.pop_back();
                } else {
                    o.pop_back();
                }
            } else {
                if (e.empty() || (!o.empty() && o.back() > e.back())) {
                    b += o.back();
                    o.pop_back();
                } else {
                    e.pop_back();
                }
            }
        }
        if (a > b) {
            cout << "Alice" << '\n';
        } else if (a < b) {
            cout << "Bob" << '\n';
        } else {
            cout << "Tie" << '\n';
        }
    }
}
