#include <bits/stdc++.h>
using namespace std;
vector<int> v;
int n, cnt[5][500], mx[5];
char str1[100005], str2[100005], str3[100005];
void f(char str[], int id) {
  for (int i = 0; str[i]; i++) {
    int x = (int)str[i];
    cnt[id][x]++;
  }
  int x = 0;
  for (int i = 0; i < 500; i++) x = max(x, cnt[id][i]);
  int l = strlen(str);
  int y = l - x;
  x = min(x + n, l);
  if (!y && n == 1) x--;
  mx[id] = x;
  return;
}
int main() {
  scanf("%d %s %s %s", &n, str1, str2, str3);
  f(str1, 1);
  f(str2, 2);
  f(str3, 3);
  int x = max(mx[1], max(mx[2], mx[3]));
  if ((mx[1] == x && mx[2] == x) || (mx[1] == x && mx[3] == x) ||
      (mx[2] == x && mx[3] == x))
    puts("Draw");
  else if (mx[1] == x)
    puts("Kuro");
  else if (mx[2] == x)
    puts("Shiro");
  else
    puts("Katie");
  return 0;
}
