#include <bits/stdc++.h>
using namespace std;
long long a[10];
int main() {
  ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
  long long n;
  cin >> n;
  for (int i = 0; i < 3; ++i) {
    long long x = 0;
    string s;
    map<char, long long> mp;
    cin >> s;
    for (int j = 0; j < s.size(); ++j) {
      mp[s[j]]++;
      x = max(x, mp[s[j]]);
    }
    if (x < s.size())
      a[i] = min((long long)s.size(), x + n);
    else {
      a[i] = x;
      if (n == 1) {
        a[i]--;
      }
    }
  }
  if ((a[0] == a[1] && a[0] >= a[2]) || (a[2] == a[1] && a[1] >= a[0]) ||
      (a[0] == a[2] && a[0] >= a[1])) {
    return cout << "Draw", 0;
  }
  if (a[0] > a[1] && a[0] > a[2]) {
    return cout << "Kuro", 0;
  }
  if (a[1] > a[0] && a[1] > a[2]) {
    return cout << "Shiro", 0;
  }
  if (a[2] > a[0] && a[2] > a[1]) {
    return cout << "Katie", 0;
  }
}
