#include <bits/stdc++.h>
using namespace std;
const int MAXN = 1e5 + 7;
const string ONE_WIN = "tokitsukaze";
const string TWO_WIN = "quailty";
const string NO_WIN = "once again";
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int n, k;
  cin >> n >> k;
  string s;
  cin >> s;
  int o = 0, z = 0;
  for (auto &v : s) {
    if (v == '1')
      o++;
    else
      ++z;
  }
  int curo = 0, curz = 0;
  for (int i = 0; i < k; ++i) {
    if (s[i] == '1')
      ++curo;
    else
      ++curz;
  }
  int ro = o - curo, rz = z - curz;
  int lo = 0, lz = 0;
  bool two_can_win = n % 2 == 0 ? k >= n / 2 : k >= n / 2 + 1;
  for (int i = 0; i <= n - k; ++i) {
    if (ro + lo == 0 || rz + lz == 0) {
      cout << ONE_WIN << '\n';
      return 0;
    }
    if (i == 0) continue;
    if (s[i - 1] == '1')
      lo++;
    else
      lz++;
    if (s[i + k - 1] == '1') {
      curo++;
      ro--;
    } else {
      curz++;
      rz--;
    }
    if (i != 0 && i < n - k) {
      two_can_win &= (lo == 0 || lz == 0);
      two_can_win &= (ro == 0 || rz == 0);
    }
  }
  if (two_can_win)
    cout << TWO_WIN << '\n';
  else
    cout << NO_WIN << '\n';
  return 0;
}
