#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m1 = 0, m2 = 0, m3 = 0, r1, r2, r3, z, q, p;
  string s1, s2, s3;
  cin >> n >> s1 >> s2 >> s3;
  sort(s1.begin(), s1.end());
  sort(s2.begin(), s2.end());
  sort(s3.begin(), s3.end());
  z = 0;
  while (z < s1.size()) {
    q = 0;
    p = z;
    while (z < s1.size() && s1[p] == s1[z]) {
      z++;
      q++;
    }
    m1 = max(m1, q);
  }
  z = 0;
  while (z < s2.size()) {
    q = 0;
    p = z;
    while (z < s2.size() && s2[p] == s2[z]) {
      z++;
      q++;
    }
    m2 = max(m2, q);
  }
  z = 0;
  while (z < s3.size()) {
    q = 0;
    p = z;
    while (z < s3.size() && s3[p] == s3[z]) {
      z++;
      q++;
    }
    m3 = max(m3, q);
  }
  if (m1 == s1.size() && n == 1)
    r1 = s1.size() - 1;
  else
    r1 = min((int)s1.size(), m1 + n);
  if (m2 == s2.size() && n == 1)
    r2 = s2.size() - 1;
  else
    r2 = min((int)s2.size(), m2 + n);
  if (m3 == s3.size() && n == 1)
    r3 = s3.size() - 1;
  else
    r3 = min((int)s3.size(), m3 + n);
  int r = max(r1, max(r2, r3));
  if (r == r1 && r == r2 || r == r2 && r == r3 || r == r1 && r == r3)
    cout << "Draw";
  else if (r == r1)
    cout << "Kuro";
  else if (r == r2)
    cout << "Shiro";
  else
    cout << "Katie";
}
