#include <bits/stdc++.h>
using namespace std;
char s[100010];
int n, k;
int sum[100010];
void print(int x) {
  if (!x)
    puts("tokitsukaze");
  else if (x == 1)
    puts("quailty");
  else
    puts("once again");
}
bool check(int l, int r, int z) {
  int le = r + 1, re = l - 1;
  for (int i = l; i <= r; i++) {
    if (s[i] - '0' == z) {
      le = min(le, i);
      re = max(re, i);
    }
  }
  if (re - le + 1 > k) return false;
  return true;
}
int main() {
  scanf("%d %d %s", &n, &k, s + 1);
  for (int i = 1; i <= n; i++) {
    sum[i] = sum[i - 1] + s[i] - '0';
  }
  for (int i = 1; i + k - 1 <= n; i++) {
    if (sum[i - 1] - sum[0] == i - 1 &&
        sum[n] - sum[i + k - 1] == n - k - i + 1) {
      print(0);
      return 0;
    } else if (sum[i - 1] - sum[0] == 0 && sum[n] - sum[i + k - 1] == 0) {
      print(0);
      return 0;
    }
  }
  bool f = true;
  if (!check(1, k, 0) || !check(1, k, 1) || !check(n - k + 1, n, 0) ||
      !check(n - k + 1, n, 1)) {
    print(2);
    return 0;
  }
  for (int i = 2; i + k <= n; i++) {
    if (sum[i - 1] - sum[0] == i - 1 && sum[n] - sum[i + k - 1] == 0 &&
        i - 1 <= k && n - i - k + 1 <= k)
      continue;
    if (sum[i - 1] - sum[0] == 0 && sum[n] - sum[i + k - 1] == n - i - k + 1 &&
        i - 1 <= k && n - i - k + 1 <= k)
      continue;
    f = false;
    break;
  }
  if (f)
    print(1);
  else
    print(2);
  return 0;
}
