#include <bits/stdc++.h>
using namespace std;
int mod = 1e9 + 7;
int main() {
  int n;
  cin >> n;
  vector<vector<int> > a(3, vector<int>(52, 0));
  vector<string> t(3);
  cerr << n << endl;
  for (int i = 0; i < 3; i++) {
    string s;
    cin >> s;
    t[i] = s;
    sort(t[i].begin(), t[i].end());
    cerr << t[i].size() << " " << t[i] << endl;
    for (int j = 0; j < s.size(); j++) {
      if ('a' <= s[j] && s[j] <= 'z')
        a[i][s[j] - 'a']++;
      else if ('A' <= s[j] && s[j] <= 'Z')
        a[i][s[j] - 'A' + 26]++;
    }
  }
  vector<int> b(3, 0);
  for (int i = 0; i < 3; i++) {
    cerr << b[i] << " -> ";
    int mx = *max_element(a[i].begin(), a[i].end());
    b[i] = mx + n;
    int tmp = b[i] - t[i].size();
    if (n == 1 && mx - t[i].size() == 0) {
      b[i] = t[i].size() - 1;
    } else if (tmp > 0) {
      b[i] = t[i].size();
    }
    cerr << b[i] << endl;
  }
  if (b[0] > b[1] && b[0] > b[2]) {
    cout << "Kuro" << endl;
  } else if (b[1] > b[0] && b[1] > b[2]) {
    cout << "Shiro" << endl;
  } else if (b[2] > b[1] && b[2] > b[0]) {
    cout << "Katie" << endl;
  } else {
    cout << "Draw" << endl;
  }
  return 0;
}
