#include <bits/stdc++.h>
using namespace std;
long long n, m, sum, L[100010], R[100010];
char s[100010];
int main() {
  scanf("%lld %lld %s", &n, &m, s + 1);
  L[0] = 1;
  for (long long i = 1; i <= n; i++) {
    if (s[i] == s[i - 1])
      L[i] = L[i - 1];
    else
      L[i] = i;
  }
  R[n + 1] = n;
  for (long long i = n; i >= 1; i--) {
    if (s[i] == s[i + 1])
      R[i] = R[i + 1];
    else
      R[i] = i;
  }
  if (R[1] == n) return printf("tokitsukaze\n") & 0;
  for (long long l = 1, r = m; r <= n; l++, r++) {
    if (L[l - 1] == 1 && R[r + 1] == n)
      if (l == 1 || r == n || (s[l - 1] == s[r + 1]))
        return printf("tokitsukaze\n") & 0;
      else {
        if (l - 1 <= m && n - r <= m) sum++;
      }
    else if (l == 1) {
      if (n - r <= m) sum++;
    } else if (r == n) {
      if (l - 1 <= m) sum++;
    }
  }
  if (sum == n - m + 1)
    printf("quailty\n");
  else
    printf("once again\n");
  return 0;
}
