#include <bits/stdc++.h>
#define rep(i,a,b) for(int i=a;i<b;i++)
#define all(x) (x).begin(),(x).end()
using namespace std;

int main() {
    
    int N, M;
    cin >> N >> M;
    
    vector<int> A(N);
    vector<int> B(M);
    rep(i,0,N) cin >> A.at(i);
    rep(i,0,M) cin >> B.at(i);
    
    map<int, int> mp;
    
    rep(i,0,1000){
        mp[i+1] = 0;
        auto itrA = find(all(A), i+1);
        if(itrA != A.end()){
            mp[i+1]++;
        }

        auto itrB = find(all(B), i+1);
        if(itrB != B.end()){
            mp[i+1]++;
        }
        
        if(mp[i+1]==1){
            cout << i+1 << ' ';
        }
    }
    
    cout << endl;
    
    return 0;
}

#include <iostream>
#include <vector>
#include <algorithm>

using namespace std;

int main() {
	int H, W;

	cin >> H >> W;

	vector<vector<char>> A(H, vector<char>(W));

	for (int i = 0; i < H; i++)
	{
		for (int j = 0; j < W; j++)
		{
			cin >> A[i][j];
		}
	}


	vector<vector<vector<int>>> DP(H, vector<vector<int>>(W, vector<int>(2, 0)));

	//初期化
	//一番右
	for (int i = H - 2; i >= 0; i--)
	{
		if (A[i + 1][W - 1] == '+') {
			DP[i][W - 1][0] = DP[i + 1][W - 1][1] + 1;
			DP[i][W - 1][1] = DP[i + 1][W - 1][0] - 1;
		}
		if (A[i + 1][W - 1] == '-') {
			DP[i][W - 1][0] = DP[i + 1][W - 1][1] - 1;
			DP[i][W - 1][1] = DP[i + 1][W - 1][0] + 1;
		}
	}

	//一番下
	for (int j = W - 2; j >= 0; j--)
	{
		if (A[H - 1][j + 1] == '+') {
			DP[H - 1][j][0] = DP[H - 1][j + 1][1] + 1;
			DP[H - 1][j][1] = DP[H - 1][j + 1][0] - 1;
		}
		if (A[H - 1][j + 1] == '-') {
			DP[H - 1][j][0] = DP[H - 1][j + 1][1] - 1;
			DP[H - 1][j][1] = DP[H - 1][j + 1][0] + 1;
		}
	}

	//値を計算
	for (int i = H - 2; i >= 0; i--)
	{
		for (int j = W - 2; j >= 0; j--)
		{
			int right = -1, down = -1;

			if (A[i][j + 1] == '+') right = 1;
			if (A[i + 1][j] == '+') down = 1;

			DP[i][j][0] = max(DP[i][j + 1][1] + right, DP[i + 1][j][1] + down);
			DP[i][j][1] = min(DP[i][j + 1][0] - right, DP[i + 1][j][0] - down);
		}
	}

	if (DP[0][0][0] == 0)
		cout << "Draw" << endl;
	else if (DP[0][0][0] > 0)
		cout << "Takahashi" << endl;
	else
		cout << "Aoki" << endl;


	return 0;
}