#include <bits/stdc++.h>
using namespace std;
int find(string &s) {
  map<char, int> counts;
  int best = 0;
  for (int i = 0; i < s.size(); i++) {
    counts[s[i]]++;
    best = max(best, counts[s[i]]);
  }
  return best;
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  int n;
  cin >> n;
  string f, s, t;
  cin >> f;
  cin >> s;
  cin >> t;
  int f_largest = find(f);
  int s_largest = find(s);
  int t_largest = find(t);
  int f_best = (n == 1 && f_largest == f.size())
                   ? (f_largest - 1)
                   : min(f_largest + n, (int)f.size());
  int s_best = (n == 1 && s_largest == s.size())
                   ? (s_largest - 1)
                   : min(s_largest + n, (int)s.size());
  int t_best = (n == 1 && t_largest == t.size())
                   ? (t_largest - 1)
                   : min(t_largest + n, (int)t.size());
  if (f_best > max(s_best, t_best)) {
    cout << "Kuro" << endl;
  } else {
    if (s_best > max(f_best, t_best)) {
      cout << "Shiro" << endl;
    } else if (t_best > max(f_best, s_best)) {
      cout << "Katie" << endl;
    } else {
      cout << "Draw" << endl;
    }
  }
  return 0;
}
