#include <bits/stdc++.h>
using namespace std;
int cnt[3][300];
int n;
string s;
int main() {
  cin >> n;
  for (int i = 0; i < 3; i++) {
    cin >> s;
    for (int j = 0; s[j]; j++) cnt[i][s[j]]++;
  }
  int maxa = 0, maxb = 0, maxc = 0;
  for (int i = 0; i < 300; i++) {
    maxa = max(maxa, cnt[0][i]);
    maxb = max(maxb, cnt[1][i]);
    maxc = max(maxc, cnt[2][i]);
  }
  if (n == 1 && maxa == (int)s.size())
    maxa--;
  else
    maxa = min(maxa + n, (int)s.size());
  if (n == 1 && maxb == (int)s.size())
    maxb--;
  else
    maxb = min(maxb + n, (int)s.size());
  if (n == 1 && maxc == (int)s.size())
    maxc--;
  else
    maxc = min(maxc + n, (int)s.size());
  if (maxa > maxb && maxa > maxc)
    cout << "Kuro" << endl;
  else if (maxb > maxa && maxb > maxc)
    cout << "Shiro" << endl;
  else if (maxc > maxa && maxc > maxb)
    cout << "Katie" << endl;
  else
    cout << "Draw" << endl;
  return 0;
}
