#include <bits/stdc++.h>
using namespace std;
string s;
vector<int> v1, v0;
int n, m;
bool solve(int p, int b) {
  int l = p, r = p + m - 1;
  if (b == 1) {
    int l1, r1;
    l1 = min(v1[0], l);
    r1 = max(v1[v1.size() - 1], r);
    if (l1 + m - 1 >= r1) return true;
    int l0, r0;
    l0 = lower_bound(v0.begin(), v0.end(), l) - v0.begin() - 1;
    if (l0 == -1) {
      l0 = n + 1;
      r0 = -1;
    } else {
      r0 = v0[l0];
      l0 = v0[0];
    }
    int tl0, tr0;
    tl0 = upper_bound(v0.begin(), v0.end(), r) - v0.begin();
    if (tl0 != v0.size()) {
      l0 = min(l0, v0[tl0]);
      r0 = max(r0, v0[v0.size() - 1]);
    }
    if (r0 == -1 || l0 + m - 1 >= r0) return true;
  } else {
    int l1, r1;
    l1 = min(v0[0], l);
    r1 = max(v0[v0.size() - 1], r);
    if (l1 + m - 1 >= r1) return true;
    int l0, r0;
    l0 = lower_bound(v1.begin(), v1.end(), l) - v1.begin() - 1;
    if (l0 == -1) {
      l0 = n + 1;
      r0 = -1;
    } else {
      r0 = v1[l0];
      l0 = v1[0];
    }
    int tl0, tr0;
    tl0 = upper_bound(v1.begin(), v1.end(), r) - v1.begin();
    if (tl0 != v1.size()) {
      l0 = min(l0, v1[tl0]);
      r0 = max(r0, v1[v1.size() - 1]);
    }
    if (r0 == -1 || l0 + m - 1 >= r0) return true;
  }
  return false;
}
int main() {
  cin >> n >> m >> s;
  for (int i = 0; i < n; ++i)
    if (s[i] == '1')
      v1.push_back(i + 1);
    else
      v0.push_back(i + 1);
  if (!v1.size() || !v0.size()) {
    cout << "tokitsukaze" << endl;
    return 0;
  }
  if (v1.size() && v1[0] + m - 1 >= v1[v1.size() - 1]) {
    cout << "tokitsukaze" << endl;
    return 0;
  }
  if (v0.size() && v0[0] + m - 1 >= v0[v0.size() - 1]) {
    cout << "tokitsukaze" << endl;
    return 0;
  }
  for (int i = 1; i <= n - m + 1; ++i) {
    if (!solve(i, 0) || !solve(i, 1)) {
      cout << "once again" << endl;
      return 0;
    }
  }
  cout << "quailty" << endl;
  return 0;
}
