#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
const int N=1e3+5,M=2e4+5,inf=0x3f3f3f3f,mod=1e9+7;
#define mst(a,b) memset(a,b,sizeof a)
#define PII pair<int,int>
#define fi first
#define se second
#define pb push_back
int main(){
	int a,b,c;cin>>a>>b>>c;
	if(a!=b){
		puts(a>b?"Takahashi":"Aoki");
	}
	else {
		puts(c==0?"Aoki":"Takahashi");
	}
	return 0;
}
#include <algorithm>
#include <cstdio>
#include <functional>
#include <iostream>
#include <cfloat>
#include <climits>
#include <cstdlib>
#include <cstring>
#include <cmath>
#include <map>
#include <unordered_map>
#include <unordered_set>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <time.h>
#include <complex>
#include <vector>
#include <limits>
#include <iomanip>
#include <cassert>
#include <numeric>
#include <chrono>
#include <random>

using namespace std;

typedef long long ll;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;

#define debug(x) cerr << #x << " = " << (x) << endl;
#define debug_pii(x) cerr << "(" << x.first << "," << x.second << ")";
#define rep(i, n) for(int i = 0;i < n;i++)
#define pb push_back
#define F first
#define S second

// template<typename _Ty1, typename _Ty2>
// ostream& operator<<(ostream& _os, const pair<_Ty1, _Ty2>& _p) {
//     _os << '(' <<_p.first << ',' << _p.second << ')';
//     return _os;
// }
//
// template<typename _Ty1, typename _Ty2>
// istream& operator>>(istream& _is, pair<_Ty1, _Ty2>& _p) {
//     _is >> _p.first >> _p.second;
//     return _is;
// }

ll pwr(ll b, ll c, ll mod) {
  if(c == 0) return 1;
  ll x = pwr(b,c/2,mod);
  if(c%2==0) return x*x%mod;
  return x*x%mod*b%mod;
}

void solve() {
  vector<vector<int>> d(10);
  d[0] = vector<int>{0};
  d[1] = vector<int>{1};
  d[2] = vector<int>{2,4,8,6};
  d[3] = vector<int>{3,9,7,1};
                  // 1 2 3 0
  d[4] = vector<int>{4,6};
  d[5] = vector<int>{5};
  d[6] = vector<int>{6};
  d[7] = vector<int>{7,9,3,1};
  d[8] = vector<int>{8,4,2,6};
  d[9] = vector<int>{9,1};

  ll a,b,c;
  cin>>a>>b>>c;
  a = a % 10;
  ll x = pwr(b%d[a].size(),c,d[a].size());
  cout<<d[a][(d[a].size()-1+x)%d[a].size()]<<endl;

}

// d+1, d+2, d+3, ...,  d'    ,... , M
// 0 [1]
// 1 [1]
// 2 [2,4,8,6,2]
// 3 [3,9,7,1,3]
// 4 [4,6,4]
// 5 [1]
// 6 [1]
// 7 [7,9,3,1,7]
// 8 [8,4,2,6,8]
// 9 [9,1,9]


int main() {

 // freopen("input.in","r",stdin);
 // freopen("output.out","w",stdout);
 // cout << fixed << setprecision(15);2000000000

 ios_base::sync_with_stdio(false);
 cin.tie(nullptr);
 // prime_factors();
 int t = 1;
 // cin >> t;
 while (t--) {
   solve();
 }

 return 0;
}
