#include <bits/stdc++.h>
const long long MAX_N = 1e5 + 10;
const long long MOD = 1e9 + 7;
using namespace std;
int n, k;
void draw() {
  cout << "once again";
  exit(0);
}
void fs() {
  cout << "tokitsukaze";
  exit(0);
}
void sc() {
  cout << "quailty";
  exit(0);
}
int calc(string s) {
  int mx1 = 0, mx2 = 0;
  char c = s[0];
  for (int i = 0; i < n; ++i) {
    if (s[i] == c)
      mx1++;
    else
      break;
  }
  for (int i = n - 1; i >= 0; --i) {
    if (s[i] == s[n - 1])
      mx2++;
    else
      break;
  }
  return max(mx1, mx2);
}
int main() {
  cin >> n >> k;
  string s;
  cin >> s;
  int mx1 = 0, mx2 = 0;
  char c = s[0];
  for (int i = 0; i < n; ++i) {
    if (s[i] == c)
      mx1++;
    else
      break;
  }
  for (int i = n - 1; i >= 0; --i) {
    if (s[i] == s[n - 1])
      mx2++;
    else
      break;
  }
  if (max(mx1, mx2) >= n - k) fs();
  if (s[0] == s[n - 1] and n - mx1 - mx2 <= k) fs();
  if (k < n - k) draw();
  if (s[0] == s[n - 1]) {
    if (n - mx1 - mx2 - 2 >= k) draw();
    sc();
  }
  string t1 = s, t2 = s;
  for (int i = 1; i <= min(n - 1, k); ++i) t1[i] = s[n - 1];
  for (int i = n - 2; i >= max(0, n - k - 1); --i) t2[i] = s[0];
  if (min(calc(t1), calc(t2)) < n - k) draw();
  sc();
  return 0;
}
