import java.io.*;
import java.util.*;
import java.lang.*;
import java.math.*;
public class Main extends Thread  {
    boolean[] prime;
    FastScanner sc;
    PrintWriter pw;
    MathF mf;
    final class FastScanner {
        BufferedReader br;
        StringTokenizer st;

        public FastScanner() {
            try {
                br = new BufferedReader(new InputStreamReader(System.in));
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
        }

        public long nlo() {
            return Long.parseLong(next());
        }

        public String next() {
            if (st.hasMoreTokens()) return st.nextToken();
            try {
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
            return st.nextToken();
        }

        public int ni() {
            return Integer.parseInt(next());
        }

        public String nli() {
            String line = "";
            if (st.hasMoreTokens()) line = st.nextToken();
            else try {
                return br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            while (st.hasMoreTokens()) line += " " + st.nextToken();
            return line;
        }

        public double nd() {
            return Double.parseDouble(next());
        }
    }
    final class MathF {
        long grtdiv(long x)
        {
            if(isPrime(x))
                return 1;
            else
            {
                long ans=0;
                long y=(long)Math.sqrt(x)+1;
                for(;y>=2;y--)
                {
                    if(x%y==0)
                        ans=Math.max(ans,Math.max(y,x/y));
                }
                return ans;
            }
        }
        boolean isPrime(long x)
        {
            for(int i=2;i*i<=x;i++)
            {
                if(x%i==0)
                {
                    return false;
                }
            }
            return true;
        }
        long[][] mul(long[][] arr,long[][] brr,int a,int b,int c,int d)
        {
            long[][] crr=new long[a][d];
            for(int i=0;i<a;i++)
            {
                for(int j=0;j<d;j++)
                {
                    for(int k=0;k<b;k++)
                    {
                        crr[i][j]+=(((arr[i][k]%1000000007)*(brr[k][j]%1000000007))%1000000007);
                    }
                }
            }
            return crr;
        }
        int sod(long a)
        {
            int ans=0;
            while(a!=0)
            {
                ans+=(a%10);
                a=a/10;
            }
            return ans;
        }
        long pow(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=pow(a,b/2);
                if(b%2==1)
                    return (x*x*a);
                else
                    return (x*x);
            }
        }
        public  long gcd(long a, long b) {
            return (b == 0 ? a : gcd(b, a % b));
        }
        public long exponent(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=exponent(a,b/2);
                x*=x;
                if(b%2==1)
                    x*=a;
                return x;
            }
        }
        public  int nod(long x) {
            int i = 0;
            while (x != 0) {
                i++;
                x = x / 10;
            }
            return i;
        }

        public  int nob(long x) {
            if(x==0)
                return 1;
            return (int) Math.floor(Math.log(x) / Math.log(2)) + 1;
        }

        public int[] FastradixSort(int[] f) {
            int[] to = new int[f.length];
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] & 0xffff)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] & 0xffff]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] >>> 16)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] >>> 16]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            return f;
        }

        public  void Primesieve(int n) {
            prime=new boolean[n];
            for (int i = 0; i < n; i++)
                prime[i] = true;
            for (int p = 3; p * p < n; p+=2) {
                if (prime[p] == true) {
                    for (int i = p * p; i < n; i += p)
                        prime[i] = false;
                }
            }
        }
    }
    public Main(ThreadGroup t,Runnable r,String s,long d )
    {
        super(t,r,s,d);
    }
    public void run()
    {
        sc=new FastScanner();
        pw=new PrintWriter(System.out);
        mf=new MathF();
        solve();
        pw.flush();
        pw.close();
    }
    public static void main(String[] args)
    {
        new Main(null,null,"",1<<28).start();
    }

    /////////////----------------------------------------/////////////
    ////////////------------------MAIN-LOGIC-------------/////////////
    ////////////----------Remember dfs reqire ----------/////////////
    ///////////---------- thread  for stack size -------/////////////
    ////////////--------------------------------------///////////////
    ArrayList<Integer>[] adj;
    int[] visit;
    int[] mrr;
    public void solve(){
        long t=1;
        while(t-->0) {
            long n=sc.nlo();
            int[] arr,brr,crr;
            arr=new int[256];
            brr=new int[256];
            crr=new int[256];
            String str=sc.next();
            int l=str.length();
            for(int i=0;i<l;i++)
            {
                arr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                brr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                crr[str.charAt(i)]++;
            }
            long a=-1,b=-1,c=-1;
            for(int i=0;i<256;i++)
            {
                a=Math.max(a,arr[i]);
                b=Math.max(b,brr[i]);
                c=Math.max(c,crr[i]);
            }
            long N,k;
            N=n;
            if(a<l)
            {
                k=(Math.min(l-1-a,n));
                n-=k;
                a+=k;
                if(n>0)
                    a=l;
            }
            else
            {
                if(n==1)
                    a=l-1;
                else if(n>1)
                    a=l;
            }
            n=N;
            if(b<l)
            {
                k=(Math.min(l-b,n));
                n-=k;
                b+=k;
                if(n>0)
                    b=l;
            }
            else
                {if(n==1)
                b=l-1;
            else if(n>1)
                b=l;}
            n=N;
            if(c<l){
            k=(Math.min(l-c,n));
            n-=k;
            c+=k;
            if(n>0)
            c=l;}
            else{
            if(n==1)
                c=l-1;
            else if(n>1)
                c=l;}

            long max=Math.max(Math.max(a,b),c);
            if(a==max&&((b!=max)&&(c!=max)))
                pw.println("Kuro");
            else if(b==max&&((c!=max)&&(a!=max)))
                pw.println("Shiro");
            else if(c==max&&((b!=max)&&(a!=max)))
                pw.println("Katie");
            else
                pw.println("Draw");
        }
    }
}


import java.io.*;
import java.util.*;
import java.lang.*;
import java.math.*;
public class Main extends Thread  {
    boolean[] prime;
    FastScanner sc;
    PrintWriter pw;
    MathF mf;
    final class FastScanner {
        BufferedReader br;
        StringTokenizer st;

        public FastScanner() {
            try {
                br = new BufferedReader(new InputStreamReader(System.in));
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
        }

        public long nlo() {
            return Long.parseLong(next());
        }

        public String next() {
            if (st.hasMoreTokens()) return st.nextToken();
            try {
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
            return st.nextToken();
        }

        public int ni() {
            return Integer.parseInt(next());
        }

        public String nli() {
            String line = "";
            if (st.hasMoreTokens()) line = st.nextToken();
            else try {
                return br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            while (st.hasMoreTokens()) line += " " + st.nextToken();
            return line;
        }

        public double nd() {
            return Double.parseDouble(next());
        }
    }
    final class MathF {
        long grtdiv(long x)
        {
            if(isPrime(x))
                return 1;
            else
            {
                long ans=0;
                long y=(long)Math.sqrt(x)+1;
                for(;y>=2;y--)
                {
                    if(x%y==0)
                        ans=Math.max(ans,Math.max(y,x/y));
                }
                return ans;
            }
        }
        boolean isPrime(long x)
        {
            for(int i=2;i*i<=x;i++)
            {
                if(x%i==0)
                {
                    return false;
                }
            }
            return true;
        }
        long[][] mul(long[][] arr,long[][] brr,int a,int b,int c,int d)
        {
            long[][] crr=new long[a][d];
            for(int i=0;i<a;i++)
            {
                for(int j=0;j<d;j++)
                {
                    for(int k=0;k<b;k++)
                    {
                        crr[i][j]+=(((arr[i][k]%1000000007)*(brr[k][j]%1000000007))%1000000007);
                    }
                }
            }
            return crr;
        }
        int sod(long a)
        {
            int ans=0;
            while(a!=0)
            {
                ans+=(a%10);
                a=a/10;
            }
            return ans;
        }
        long pow(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=pow(a,b/2);
                if(b%2==1)
                    return (x*x*a);
                else
                    return (x*x);
            }
        }
        public  long gcd(long a, long b) {
            return (b == 0 ? a : gcd(b, a % b));
        }
        public long exponent(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=exponent(a,b/2);
                x*=x;
                if(b%2==1)
                    x*=a;
                return x;
            }
        }
        public  int nod(long x) {
            int i = 0;
            while (x != 0) {
                i++;
                x = x / 10;
            }
            return i;
        }

        public  int nob(long x) {
            if(x==0)
                return 1;
            return (int) Math.floor(Math.log(x) / Math.log(2)) + 1;
        }

        public int[] FastradixSort(int[] f) {
            int[] to = new int[f.length];
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] & 0xffff)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] & 0xffff]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] >>> 16)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] >>> 16]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            return f;
        }

        public  void Primesieve(int n) {
            prime=new boolean[n];
            for (int i = 0; i < n; i++)
                prime[i] = true;
            for (int p = 3; p * p < n; p+=2) {
                if (prime[p] == true) {
                    for (int i = p * p; i < n; i += p)
                        prime[i] = false;
                }
            }
        }
    }
    public Main(ThreadGroup t,Runnable r,String s,long d )
    {
        super(t,r,s,d);
    }
    public void run()
    {
        sc=new FastScanner();
        pw=new PrintWriter(System.out);
        mf=new MathF();
        solve();
        pw.flush();
        pw.close();
    }
    public static void main(String[] args)
    {
        new Main(null,null,"",1<<28).start();
    }

    /////////////----------------------------------------/////////////
    ////////////------------------MAIN-LOGIC-------------/////////////
    ////////////----------Remember dfs reqire ----------/////////////
    ///////////---------- thread  for stack size -------/////////////
    ////////////--------------------------------------///////////////
    ArrayList<Integer>[] adj;
    int[] visit;
    int[] mrr;
    public void solve(){
        long t=1;
        while(t-->0) {
            long n=sc.nlo();
            int[] arr,brr,crr;
            arr=new int[256];
            brr=new int[256];
            crr=new int[256];
            String str=sc.next();
            int l=str.length();
            for(int i=0;i<l;i++)
            {
                arr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                brr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                crr[str.charAt(i)]++;
            }
            long a=-1,b=-1,c=-1;
            for(int i=0;i<256;i++)
            {
                a=Math.max(a,arr[i]);
                b=Math.max(b,brr[i]);
                c=Math.max(c,crr[i]);
            }
            long N=n,k;
            k=(Math.min(l-a,n));
            n-=k;
            a+=k;
            if(n==1)
                a=l-1;
            else if(n>1)
                a=l;
            n=N;
            k=(Math.min(l-b,n));
            n-=k;
            b+=k;
            if(n==1)
                b=l-1;
            else if(n>1)
                b=l;
            n=N;
            k=(Math.min(l-c,n));
            n-=k;
            c+=k;
            if(n==1)
                c=l-1;
            else if(n>1)
                c=l;

            long max=Math.max(Math.max(a,b),c);
            if(a==max&&((b!=max)&&(c!=max)))
                pw.println("Kuro");
            else if(b==max&&((c!=max)&&(a!=max)))
                pw.println("Shiro");
            else if(c==max&&((b!=max)&&(a!=max)))
                pw.println("Katie");
            else
                pw.println("Draw");
        }
    }
}


import java.io.*;
import java.util.*;
import java.lang.*;
import java.math.*;
public class Main extends Thread  {
    boolean[] prime;
    FastScanner sc;
    PrintWriter pw;
    MathF mf;
    final class FastScanner {
        BufferedReader br;
        StringTokenizer st;

        public FastScanner() {
            try {
                br = new BufferedReader(new InputStreamReader(System.in));
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
        }

        public long nlo() {
            return Long.parseLong(next());
        }

        public String next() {
            if (st.hasMoreTokens()) return st.nextToken();
            try {
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
            return st.nextToken();
        }

        public int ni() {
            return Integer.parseInt(next());
        }

        public String nli() {
            String line = "";
            if (st.hasMoreTokens()) line = st.nextToken();
            else try {
                return br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            while (st.hasMoreTokens()) line += " " + st.nextToken();
            return line;
        }

        public double nd() {
            return Double.parseDouble(next());
        }
    }
    final class MathF {
        long grtdiv(long x)
        {
            if(isPrime(x))
                return 1;
            else
            {
                long ans=0;
                long y=(long)Math.sqrt(x)+1;
                for(;y>=2;y--)
                {
                    if(x%y==0)
                        ans=Math.max(ans,Math.max(y,x/y));
                }
                return ans;
            }
        }
        boolean isPrime(long x)
        {
            for(int i=2;i*i<=x;i++)
            {
                if(x%i==0)
                {
                    return false;
                }
            }
            return true;
        }
        long[][] mul(long[][] arr,long[][] brr,int a,int b,int c,int d)
        {
            long[][] crr=new long[a][d];
            for(int i=0;i<a;i++)
            {
                for(int j=0;j<d;j++)
                {
                    for(int k=0;k<b;k++)
                    {
                        crr[i][j]+=(((arr[i][k]%1000000007)*(brr[k][j]%1000000007))%1000000007);
                    }
                }
            }
            return crr;
        }
        int sod(long a)
        {
            int ans=0;
            while(a!=0)
            {
                ans+=(a%10);
                a=a/10;
            }
            return ans;
        }
        long pow(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=pow(a,b/2);
                if(b%2==1)
                    return (x*x*a);
                else
                    return (x*x);
            }
        }
        public  long gcd(long a, long b) {
            return (b == 0 ? a : gcd(b, a % b));
        }
        public long exponent(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=exponent(a,b/2);
                x*=x;
                if(b%2==1)
                    x*=a;
                return x;
            }
        }
        public  int nod(long x) {
            int i = 0;
            while (x != 0) {
                i++;
                x = x / 10;
            }
            return i;
        }

        public  int nob(long x) {
            if(x==0)
                return 1;
            return (int) Math.floor(Math.log(x) / Math.log(2)) + 1;
        }

        public int[] FastradixSort(int[] f) {
            int[] to = new int[f.length];
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] & 0xffff)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] & 0xffff]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] >>> 16)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] >>> 16]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            return f;
        }

        public  void Primesieve(int n) {
            prime=new boolean[n];
            for (int i = 0; i < n; i++)
                prime[i] = true;
            for (int p = 3; p * p < n; p+=2) {
                if (prime[p] == true) {
                    for (int i = p * p; i < n; i += p)
                        prime[i] = false;
                }
            }
        }
    }
    public Main(ThreadGroup t,Runnable r,String s,long d )
    {
        super(t,r,s,d);
    }
    public void run()
    {
        sc=new FastScanner();
        pw=new PrintWriter(System.out);
        mf=new MathF();
        solve();
        pw.flush();
        pw.close();
    }
    public static void main(String[] args)
    {
        new Main(null,null,"",1<<28).start();
    }

    /////////////----------------------------------------/////////////
    ////////////------------------MAIN-LOGIC-------------/////////////
    ////////////----------Remember dfs reqire ----------/////////////
    ///////////---------- thread  for stack size -------/////////////
    ////////////--------------------------------------///////////////
    ArrayList<Integer>[] adj;
    int[] visit;
    int[] mrr;
    public void solve(){
        long t=1;
        while(t-->0) {
            long n=sc.nlo();
            int[] arr,brr,crr;
            arr=new int[256];
            brr=new int[256];
            crr=new int[256];
            String str=sc.next();
            int l=str.length();
            for(int i=0;i<l;i++)
            {
                arr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                brr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                crr[str.charAt(i)]++;
            }
            long a=-1,b=-1,c=-1;
            for(int i=0;i<256;i++)
            {
                a=Math.max(a,arr[i]);
                b=Math.max(b,brr[i]);
                c=Math.max(c,crr[i]);
            }
            long N,k;
            N=n;
            if(a<l)
            {
                k=(Math.min(l-1-a,n));
                n-=k;
                a+=k;
            }
            if(n==1)
                a=l-1;
            else if(n>1)
                a=l;
            n=N;
            if(b<l)
            {
                k=(Math.min(l-b,n));
                n-=k;
                b+=k;
            }
            if(n==1)
                b=l-1;
            else if(n>1)
                b=l;
            n=N;
            if(c<l){
            k=(Math.min(l-c,n));
            n-=k;
            c+=k;}
            if(n==1)
                c=l-1;
            else if(n>1)
                c=l;

            long max=Math.max(Math.max(a,b),c);
            if(a==max&&((b!=max)&&(c!=max)))
                pw.println("Kuro");
            else if(b==max&&((c!=max)&&(a!=max)))
                pw.println("Shiro");
            else if(c==max&&((b!=max)&&(a!=max)))
                pw.println("Katie");
            else
                pw.println("Draw");
        }
    }
}


import java.io.*;
import java.util.*;
import java.lang.*;
import java.math.*;
public class Main extends Thread  {
    boolean[] prime;
    FastScanner sc;
    PrintWriter pw;
    MathF mf;
    final class FastScanner {
        BufferedReader br;
        StringTokenizer st;

        public FastScanner() {
            try {
                br = new BufferedReader(new InputStreamReader(System.in));
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
        }

        public long nlo() {
            return Long.parseLong(next());
        }

        public String next() {
            if (st.hasMoreTokens()) return st.nextToken();
            try {
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
            return st.nextToken();
        }

        public int ni() {
            return Integer.parseInt(next());
        }

        public String nli() {
            String line = "";
            if (st.hasMoreTokens()) line = st.nextToken();
            else try {
                return br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            while (st.hasMoreTokens()) line += " " + st.nextToken();
            return line;
        }

        public double nd() {
            return Double.parseDouble(next());
        }
    }
    final class MathF {
        long grtdiv(long x)
        {
            if(isPrime(x))
                return 1;
            else
            {
                long ans=0;
                long y=(long)Math.sqrt(x)+1;
                for(;y>=2;y--)
                {
                    if(x%y==0)
                        ans=Math.max(ans,Math.max(y,x/y));
                }
                return ans;
            }
        }
        boolean isPrime(long x)
        {
            for(int i=2;i*i<=x;i++)
            {
                if(x%i==0)
                {
                    return false;
                }
            }
            return true;
        }
        long[][] mul(long[][] arr,long[][] brr,int a,int b,int c,int d)
        {
            long[][] crr=new long[a][d];
            for(int i=0;i<a;i++)
            {
                for(int j=0;j<d;j++)
                {
                    for(int k=0;k<b;k++)
                    {
                        crr[i][j]+=(((arr[i][k]%1000000007)*(brr[k][j]%1000000007))%1000000007);
                    }
                }
            }
            return crr;
        }
        int sod(long a)
        {
            int ans=0;
            while(a!=0)
            {
                ans+=(a%10);
                a=a/10;
            }
            return ans;
        }
        long pow(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=pow(a,b/2);
                if(b%2==1)
                    return (x*x*a);
                else
                    return (x*x);
            }
        }
        public  long gcd(long a, long b) {
            return (b == 0 ? a : gcd(b, a % b));
        }
        public long exponent(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=exponent(a,b/2);
                x*=x;
                if(b%2==1)
                    x*=a;
                return x;
            }
        }
        public  int nod(long x) {
            int i = 0;
            while (x != 0) {
                i++;
                x = x / 10;
            }
            return i;
        }

        public  int nob(long x) {
            if(x==0)
                return 1;
            return (int) Math.floor(Math.log(x) / Math.log(2)) + 1;
        }

        public int[] FastradixSort(int[] f) {
            int[] to = new int[f.length];
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] & 0xffff)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] & 0xffff]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] >>> 16)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] >>> 16]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            return f;
        }

        public  void Primesieve(int n) {
            prime=new boolean[n];
            for (int i = 0; i < n; i++)
                prime[i] = true;
            for (int p = 3; p * p < n; p+=2) {
                if (prime[p] == true) {
                    for (int i = p * p; i < n; i += p)
                        prime[i] = false;
                }
            }
        }
    }
    public Main(ThreadGroup t,Runnable r,String s,long d )
    {
        super(t,r,s,d);
    }
    public void run()
    {
        sc=new FastScanner();
        pw=new PrintWriter(System.out);
        mf=new MathF();
        solve();
        pw.flush();
        pw.close();
    }
    public static void main(String[] args)
    {
        new Main(null,null,"",1<<28).start();
    }

    /////////////----------------------------------------/////////////
    ////////////------------------MAIN-LOGIC-------------/////////////
    ////////////----------Remember dfs reqire ----------/////////////
    ///////////---------- thread  for stack size -------/////////////
    ////////////--------------------------------------///////////////
    ArrayList<Integer>[] adj;
    int[] visit;
    int[] mrr;
    public void solve(){
        long t=1;
        while(t-->0) {
            long n=sc.nlo();
            int[] arr,brr,crr;
            arr=new int[256];
            brr=new int[256];
            crr=new int[256];
            String str=sc.next();
            int l=str.length();
            for(int i=0;i<l;i++)
            {
                arr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                brr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                crr[str.charAt(i)]++;
            }
            long a=-1,b=-1,c=-1;
            for(int i=0;i<256;i++)
            {
                a=Math.max(a,arr[i]);
                b=Math.max(b,brr[i]);
                c=Math.max(c,crr[i]);
            }
            long N=n,k;
            k=(Math.min(l-a,n));
            n-=k;
            a+=k;
            if(n>0)
            {
                if(n%2==0)
                    a=l;
                else
                    a=l-1;
            }
            n=N;
            k=(Math.min(l-b,n));
            n-=k;
            b+=k;
            if(n>0)
            {
                if(n%2==0)
                    b=l;
                else
                    b=l-1;
            }
            n=N;
            k=(Math.min(l-c,n));
            n-=k;
            c+=k;
            if(n>0)
            {
                if(n%2==0)
                    c=l;
                else
                    c=l-1;
            }

            long max=Math.max(Math.max(a,b),c);
            if(a==max&&((b!=max)&&(c!=max)))
                pw.println("Kuro");
            else if(b==max&&((c!=max)&&(a!=max)))
                pw.println("Shiro");
            else if(c==max&&((b!=max)&&(a!=max)))
                pw.println("Katie");
            else
                pw.println("Draw");
        }
    }
}


import java.io.*;
import java.util.*;
import java.lang.*;
import java.math.*;
public class Main extends Thread  {
    boolean[] prime;
    FastScanner sc;
    PrintWriter pw;
    MathF mf;
    final class FastScanner {
        BufferedReader br;
        StringTokenizer st;

        public FastScanner() {
            try {
                br = new BufferedReader(new InputStreamReader(System.in));
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
        }

        public long nlo() {
            return Long.parseLong(next());
        }

        public String next() {
            if (st.hasMoreTokens()) return st.nextToken();
            try {
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
            return st.nextToken();
        }

        public int ni() {
            return Integer.parseInt(next());
        }

        public String nli() {
            String line = "";
            if (st.hasMoreTokens()) line = st.nextToken();
            else try {
                return br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            while (st.hasMoreTokens()) line += " " + st.nextToken();
            return line;
        }

        public double nd() {
            return Double.parseDouble(next());
        }
    }
    final class MathF {
        long grtdiv(long x)
        {
            if(isPrime(x))
                return 1;
            else
            {
                long ans=0;
                long y=(long)Math.sqrt(x)+1;
                for(;y>=2;y--)
                {
                    if(x%y==0)
                        ans=Math.max(ans,Math.max(y,x/y));
                }
                return ans;
            }
        }
        boolean isPrime(long x)
        {
            for(int i=2;i*i<=x;i++)
            {
                if(x%i==0)
                {
                    return false;
                }
            }
            return true;
        }
        long[][] mul(long[][] arr,long[][] brr,int a,int b,int c,int d)
        {
            long[][] crr=new long[a][d];
            for(int i=0;i<a;i++)
            {
                for(int j=0;j<d;j++)
                {
                    for(int k=0;k<b;k++)
                    {
                        crr[i][j]+=(((arr[i][k]%1000000007)*(brr[k][j]%1000000007))%1000000007);
                    }
                }
            }
            return crr;
        }
        int sod(long a)
        {
            int ans=0;
            while(a!=0)
            {
                ans+=(a%10);
                a=a/10;
            }
            return ans;
        }
        long pow(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=pow(a,b/2);
                if(b%2==1)
                    return (x*x*a);
                else
                    return (x*x);
            }
        }
        public  long gcd(long a, long b) {
            return (b == 0 ? a : gcd(b, a % b));
        }
        public long exponent(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=exponent(a,b/2);
                x*=x;
                if(b%2==1)
                    x*=a;
                return x;
            }
        }
        public  int nod(long x) {
            int i = 0;
            while (x != 0) {
                i++;
                x = x / 10;
            }
            return i;
        }

        public  int nob(long x) {
            if(x==0)
                return 1;
            return (int) Math.floor(Math.log(x) / Math.log(2)) + 1;
        }

        public int[] FastradixSort(int[] f) {
            int[] to = new int[f.length];
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] & 0xffff)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] & 0xffff]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] >>> 16)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] >>> 16]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            return f;
        }

        public  void Primesieve(int n) {
            prime=new boolean[n];
            for (int i = 0; i < n; i++)
                prime[i] = true;
            for (int p = 3; p * p < n; p+=2) {
                if (prime[p] == true) {
                    for (int i = p * p; i < n; i += p)
                        prime[i] = false;
                }
            }
        }
    }
    public Main(ThreadGroup t,Runnable r,String s,long d )
    {
        super(t,r,s,d);
    }
    public void run()
    {
        sc=new FastScanner();
        pw=new PrintWriter(System.out);
        mf=new MathF();
        solve();
        pw.flush();
        pw.close();
    }
    public static void main(String[] args)
    {
        new Main(null,null,"",1<<28).start();
    }

    /////////////----------------------------------------/////////////
    ////////////------------------MAIN-LOGIC-------------/////////////
    ////////////----------Remember dfs reqire ----------/////////////
    ///////////---------- thread  for stack size -------/////////////
    ////////////--------------------------------------///////////////
    ArrayList<Integer>[] adj;
    int[] visit;
    int[] mrr;
    public void solve(){
        long t=1;
        while(t-->0) {
            long n=sc.nlo();
            int[] arr,brr,crr;
            arr=new int[256];
            brr=new int[256];
            crr=new int[256];
            String str=sc.next();
            int l=str.length();
            for(int i=0;i<l;i++)
            {
                arr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                brr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                crr[str.charAt(i)]++;
            }
            long a=-1,b=-1,c=-1;
            for(int i=0;i<256;i++)
            {
                a=Math.max(a,arr[i]);
                b=Math.max(b,brr[i]);
                c=Math.max(c,crr[i]);
            }
            long N=n,k;
            k=(Math.min(l-a,n));
            n-=k;
            a+=k;
            if(n==1)
                a=l;
            else
                a=l-1;
            n=N;
            k=(Math.min(l-b,n));
            n-=k;
            b+=k;
            if(n==1)
                b=l;
            else
                b=l-1;
            n=N;
            k=(Math.min(l-c,n));
            n-=k;
            c+=k;

            if(n==1)
                c=l;
            else
                c=l-1;

            long max=Math.max(Math.max(a,b),c);
            if(a==max&&((b!=max)&&(c!=max)))
                pw.println("Kuro");
            else if(b==max&&((c!=max)&&(a!=max)))
                pw.println("Shiro");
            else if(c==max&&((b!=max)&&(a!=max)))
                pw.println("Katie");
            else
                pw.println("Draw");
        }
    }
}


import java.io.*;
import java.util.*;
import java.lang.*;
import java.math.*;
public class Main extends Thread  {
    boolean[] prime;
    FastScanner sc;
    PrintWriter pw;
    MathF mf;
    final class FastScanner {
        BufferedReader br;
        StringTokenizer st;

        public FastScanner() {
            try {
                br = new BufferedReader(new InputStreamReader(System.in));
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
        }

        public long nlo() {
            return Long.parseLong(next());
        }

        public String next() {
            if (st.hasMoreTokens()) return st.nextToken();
            try {
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
            return st.nextToken();
        }

        public int ni() {
            return Integer.parseInt(next());
        }

        public String nli() {
            String line = "";
            if (st.hasMoreTokens()) line = st.nextToken();
            else try {
                return br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            while (st.hasMoreTokens()) line += " " + st.nextToken();
            return line;
        }

        public double nd() {
            return Double.parseDouble(next());
        }
    }
    final class MathF {
        long grtdiv(long x)
        {
            if(isPrime(x))
                return 1;
            else
            {
                long ans=0;
                long y=(long)Math.sqrt(x)+1;
                for(;y>=2;y--)
                {
                    if(x%y==0)
                        ans=Math.max(ans,Math.max(y,x/y));
                }
                return ans;
            }
        }
        boolean isPrime(long x)
        {
            for(int i=2;i*i<=x;i++)
            {
                if(x%i==0)
                {
                    return false;
                }
            }
            return true;
        }
        long[][] mul(long[][] arr,long[][] brr,int a,int b,int c,int d)
        {
            long[][] crr=new long[a][d];
            for(int i=0;i<a;i++)
            {
                for(int j=0;j<d;j++)
                {
                    for(int k=0;k<b;k++)
                    {
                        crr[i][j]+=(((arr[i][k]%1000000007)*(brr[k][j]%1000000007))%1000000007);
                    }
                }
            }
            return crr;
        }
        int sod(long a)
        {
            int ans=0;
            while(a!=0)
            {
                ans+=(a%10);
                a=a/10;
            }
            return ans;
        }
        long pow(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=pow(a,b/2);
                if(b%2==1)
                    return (x*x*a);
                else
                    return (x*x);
            }
        }
        public  long gcd(long a, long b) {
            return (b == 0 ? a : gcd(b, a % b));
        }
        public long exponent(long a,long b)
        {
            if(b==0)
                return 1;
            else
            {
                long x=exponent(a,b/2);
                x*=x;
                if(b%2==1)
                    x*=a;
                return x;
            }
        }
        public  int nod(long x) {
            int i = 0;
            while (x != 0) {
                i++;
                x = x / 10;
            }
            return i;
        }

        public  int nob(long x) {
            if(x==0)
                return 1;
            return (int) Math.floor(Math.log(x) / Math.log(2)) + 1;
        }

        public int[] FastradixSort(int[] f) {
            int[] to = new int[f.length];
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] & 0xffff)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] & 0xffff]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            {
                int[] b = new int[65537];
                for (int i = 0; i < f.length; i++) b[1 + (f[i] >>> 16)]++;
                for (int i = 1; i <= 65536; i++) b[i] += b[i - 1];
                for (int i = 0; i < f.length; i++) to[b[f[i] >>> 16]++] = f[i];
                int[] d = f;
                f = to;
                to = d;
            }
            return f;
        }

        public  void Primesieve(int n) {
            prime=new boolean[n];
            for (int i = 0; i < n; i++)
                prime[i] = true;
            for (int p = 3; p * p < n; p+=2) {
                if (prime[p] == true) {
                    for (int i = p * p; i < n; i += p)
                        prime[i] = false;
                }
            }
        }
    }
    public Main(ThreadGroup t,Runnable r,String s,long d )
    {
        super(t,r,s,d);
    }
    public void run()
    {
        sc=new FastScanner();
        pw=new PrintWriter(System.out);
        mf=new MathF();
        solve();
        pw.flush();
        pw.close();
    }
    public static void main(String[] args)
    {
        new Main(null,null,"",1<<28).start();
    }

    /////////////----------------------------------------/////////////
    ////////////------------------MAIN-LOGIC-------------/////////////
    ////////////----------Remember dfs reqire ----------/////////////
    ///////////---------- thread  for stack size -------/////////////
    ////////////--------------------------------------///////////////
    ArrayList<Integer>[] adj;
    int[] visit;
    int[] mrr;
    public void solve(){
        long t=1;
        while(t-->0) {
            long n=sc.nlo();
            int[] arr,brr,crr;
            arr=new int[256];
            brr=new int[256];
            crr=new int[256];
            String str=sc.next();
            int l=str.length();
            for(int i=0;i<l;i++)
            {
                arr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                brr[str.charAt(i)]++;
            }
            str=sc.next();
            l=str.length();
            for(int i=0;i<l;i++)
            {
                crr[str.charAt(i)]++;
            }
            long a=-1,b=-1,c=-1;
            for(int i=0;i<256;i++)
            {
                a=Math.max(a,arr[i]);
                b=Math.max(b,brr[i]);
                c=Math.max(c,crr[i]);
            }
            a+=(Math.min(l-a,n));
            b+=(Math.min(l-b,n));
            c+=(Math.min(l-c,n));
            long max=Math.max(Math.max(a,b),c);
            if(a==max&&((b!=max)&&(c!=max)))
                pw.println("Kuro");
            else if(b==max&&((c!=max)&&(a!=max)))
                pw.println("Shiro");
            else if(c==max&&((b!=max)&&(a!=max)))
                pw.println("Katie");
            else
                pw.println("Draw");
        }
    }
}


import java.util.Arrays;
import java.util.Iterator;
import java.util.PrimitiveIterator;
import java.util.Scanner;
import java.util.function.Supplier;
import java.util.stream.IntStream;
import java.util.stream.Stream;

public class Main{
	static Scanner s=new Scanner(System.in);

	void solve(){
		int n=gInt();
		int[][]score=new int[3][52];
		int[]r= {0,0,0};
		for(int v=0;v<3;++v) {
			int V=v;
			String str=s.next();
			str.chars()
			.map(i->i<='Z'?i-'A':i-'a'+26)
			.forEach(i->++score[V][i]);
			r[v]=Arrays.stream(score[V])
					.map(i->{
						int j=i+n;
						return j<=str.length()?j:j-(str.length()-j)%2;
					})
					.max().getAsInt();
		}

		if(r[0]>r[1]&&r[0]>r[2])
			System.out.println("Kuro");
		else if(r[1]>r[0]&&r[1]>r[2])
			System.out.println("Shiro");
		else if(r[2]>r[0]&&r[2]>r[1])
			System.out.println("Katie");
		else
			System.out.println("Draw");
	}

	public static void main(String[] A){
		new Main().solve();
	}

	static int gInt(){
		return Integer.parseInt(s.next());
	}
	static long gLong(){
		return Long.parseLong(s.next());
	}
	static double gDouble(){
		return Double.parseDouble(s.next());
	}

	SupplyingIterator<Integer> ints(int n){
		return new SupplyingIterator<>(n,Main::gInt);
	}
	SupplyingIterator<Long> longs(int n){
		return new SupplyingIterator<>(n,Main::gLong);
	}
	SupplyingIterator<Double> doubles(int n){
		return new SupplyingIterator<>(n,Main::gDouble);
	}
	SupplyingIterator<String> strs(int n){
		return new SupplyingIterator<>(n,s::next);
	}

	Range rep(int i){
		return Range.rep(i);
	}
	Range rep(int f,int t,int d){
		return Range.rep(f,t,d);
	}
	Range rep(int f,int t){
		return rep(f,t,1);
	}
	Range rrep(int f,int t){
		return rep(t,f,-1);
	}

	IntStream REP(int v){
		return IntStream.range(0,v);
	}
	IntStream REP(int l,int r){
		return IntStream.rangeClosed(l,r);
	}

	IntStream INTS(int n){
		return IntStream.generate(Main::gInt).limit(n);
	}
	Stream<String> STRS(int n){
		return Stream.generate(s::next).limit(n);
	}

}
class SupplyingIterator<T> implements Iterable<T>,Iterator<T>{
	int			t;
	Supplier<T>	supplier;

	SupplyingIterator(int t,Supplier<T> supplier){
		this.t=t;
		this.supplier=supplier;
	}

	@Override
	public Iterator<T> iterator(){
		return this;
	}

	@Override
	public boolean hasNext(){
		return t>0;
	}

	@Override
	public T next(){
		--t;
		return supplier.get();
	}

}
class Range implements Iterable<Integer>,PrimitiveIterator.OfInt{
	int to,cur,d;

	Range(int from,int to,int d){
		this.cur=from-d;
		this.to=to;
		this.d=d;
	}

	Range(int n){
		this(0,n-1,1);
	}

	@Override
	public Iterator<Integer> iterator(){
		return this;
	}

	@Override
	public boolean hasNext(){
		return cur+d==to||(cur!=to&&(cur<to==cur+d<to));
	}

	@Override
	public int nextInt(){
		return cur+=d;
	}

	static Range rep(int i){
		return new Range(i);
	}
	static Range rep(int f,int t,int d){
		return new Range(f,t,d);
	}
	static Range rep(int f,int t){
		return rep(f,t,1);
	}
	static Range rrep(int f,int t){
		return rep(f,t,-1);
	}

}


import java.util.Arrays;
import java.util.Iterator;
import java.util.PrimitiveIterator;
import java.util.Scanner;
import java.util.function.Supplier;
import java.util.stream.IntStream;
import java.util.stream.Stream;

public class Main{
	static Scanner s=new Scanner(System.in);

	void solve(){
		int n=gInt();
		int[][]score=new int[3][52];
		int[]r= {0,0,0};
		for(int v=0;v<3;++v) {
			int V=v;
			String str=s.next();
			str.chars()
			.map(i->i<='Z'?i-'A':i-'a'+26)
			.forEach(i->++score[V][i]);
			r[v]=Arrays.stream(score[V])
					.map(i->i==str.length()&&n==1?i-1:Math.min(str.length(),i+n))
					.max().getAsInt();
		}

		if(r[0]>r[1]&&r[0]>r[2])
			System.out.println("Kuro");
		else if(r[1]>r[0]&&r[1]>r[2])
			System.out.println("Shiro");
		else if(r[2]>r[0]&&r[2]>r[1])
			System.out.println("Katie");
		else
			System.out.println("Draw");
	}

	public static void main(String[] A){
		new Main().solve();
	}

	static int gInt(){
		return Integer.parseInt(s.next());
	}
	static long gLong(){
		return Long.parseLong(s.next());
	}
	static double gDouble(){
		return Double.parseDouble(s.next());
	}

	SupplyingIterator<Integer> ints(int n){
		return new SupplyingIterator<>(n,Main::gInt);
	}
	SupplyingIterator<Long> longs(int n){
		return new SupplyingIterator<>(n,Main::gLong);
	}
	SupplyingIterator<Double> doubles(int n){
		return new SupplyingIterator<>(n,Main::gDouble);
	}
	SupplyingIterator<String> strs(int n){
		return new SupplyingIterator<>(n,s::next);
	}

	Range rep(int i){
		return Range.rep(i);
	}
	Range rep(int f,int t,int d){
		return Range.rep(f,t,d);
	}
	Range rep(int f,int t){
		return rep(f,t,1);
	}
	Range rrep(int f,int t){
		return rep(t,f,-1);
	}

	IntStream REP(int v){
		return IntStream.range(0,v);
	}
	IntStream REP(int l,int r){
		return IntStream.rangeClosed(l,r);
	}

	IntStream INTS(int n){
		return IntStream.generate(Main::gInt).limit(n);
	}
	Stream<String> STRS(int n){
		return Stream.generate(s::next).limit(n);
	}

}
class SupplyingIterator<T> implements Iterable<T>,Iterator<T>{
	int			t;
	Supplier<T>	supplier;

	SupplyingIterator(int t,Supplier<T> supplier){
		this.t=t;
		this.supplier=supplier;
	}

	@Override
	public Iterator<T> iterator(){
		return this;
	}

	@Override
	public boolean hasNext(){
		return t>0;
	}

	@Override
	public T next(){
		--t;
		return supplier.get();
	}

}
class Range implements Iterable<Integer>,PrimitiveIterator.OfInt{
	int to,cur,d;

	Range(int from,int to,int d){
		this.cur=from-d;
		this.to=to;
		this.d=d;
	}

	Range(int n){
		this(0,n-1,1);
	}

	@Override
	public Iterator<Integer> iterator(){
		return this;
	}

	@Override
	public boolean hasNext(){
		return cur+d==to||(cur!=to&&(cur<to==cur+d<to));
	}

	@Override
	public int nextInt(){
		return cur+=d;
	}

	static Range rep(int i){
		return new Range(i);
	}
	static Range rep(int f,int t,int d){
		return new Range(f,t,d);
	}
	static Range rep(int f,int t){
		return rep(f,t,1);
	}
	static Range rrep(int f,int t){
		return rep(f,t,-1);
	}

}


import java.util.Arrays;
import java.util.Iterator;
import java.util.PrimitiveIterator;
import java.util.Scanner;
import java.util.function.Supplier;
import java.util.stream.IntStream;
import java.util.stream.Stream;

public class Main{
	static Scanner s=new Scanner(System.in);

	void solve(){
		int n=gInt();
		int[][]score=new int[3][52];
		int[]r= {0,0,0};
		for(int v=0;v<3;++v) {
			int V=v;
			String str=s.next();
			str.chars()
			.map(i->i<'Z'?i-'A':i-'a'+26)
			.forEach(i->++score[V][i]);
			r[v]=Arrays.stream(score[V])
					.max().getAsInt();
			r[v]=Math.min(str.length(),r[v]+n);
		}

		if(r[0]>r[1]&&r[0]>r[2])
			System.out.println("Kuro");
		else if(r[1]>r[0]&&r[1]>r[2])
			System.out.println("Shiro");
		else if(r[2]>r[0]&&r[2]>r[1])
			System.out.println("Katie");
		else
			System.out.println("Draw");
	}

	public static void main(String[] A){
		new Main().solve();
	}

	static int gInt(){
		return Integer.parseInt(s.next());
	}
	static long gLong(){
		return Long.parseLong(s.next());
	}
	static double gDouble(){
		return Double.parseDouble(s.next());
	}

	SupplyingIterator<Integer> ints(int n){
		return new SupplyingIterator<>(n,Main::gInt);
	}
	SupplyingIterator<Long> longs(int n){
		return new SupplyingIterator<>(n,Main::gLong);
	}
	SupplyingIterator<Double> doubles(int n){
		return new SupplyingIterator<>(n,Main::gDouble);
	}
	SupplyingIterator<String> strs(int n){
		return new SupplyingIterator<>(n,s::next);
	}

	Range rep(int i){
		return Range.rep(i);
	}
	Range rep(int f,int t,int d){
		return Range.rep(f,t,d);
	}
	Range rep(int f,int t){
		return rep(f,t,1);
	}
	Range rrep(int f,int t){
		return rep(t,f,-1);
	}

	IntStream REP(int v){
		return IntStream.range(0,v);
	}
	IntStream REP(int l,int r){
		return IntStream.rangeClosed(l,r);
	}

	IntStream INTS(int n){
		return IntStream.generate(Main::gInt).limit(n);
	}
	Stream<String> STRS(int n){
		return Stream.generate(s::next).limit(n);
	}

}
class SupplyingIterator<T> implements Iterable<T>,Iterator<T>{
	int			t;
	Supplier<T>	supplier;

	SupplyingIterator(int t,Supplier<T> supplier){
		this.t=t;
		this.supplier=supplier;
	}

	@Override
	public Iterator<T> iterator(){
		return this;
	}

	@Override
	public boolean hasNext(){
		return t>0;
	}

	@Override
	public T next(){
		--t;
		return supplier.get();
	}

}
class Range implements Iterable<Integer>,PrimitiveIterator.OfInt{
	int to,cur,d;

	Range(int from,int to,int d){
		this.cur=from-d;
		this.to=to;
		this.d=d;
	}

	Range(int n){
		this(0,n-1,1);
	}

	@Override
	public Iterator<Integer> iterator(){
		return this;
	}

	@Override
	public boolean hasNext(){
		return cur+d==to||(cur!=to&&(cur<to==cur+d<to));
	}

	@Override
	public int nextInt(){
		return cur+=d;
	}

	static Range rep(int i){
		return new Range(i);
	}
	static Range rep(int f,int t,int d){
		return new Range(f,t,d);
	}
	static Range rep(int f,int t){
		return rep(f,t,1);
	}
	static Range rrep(int f,int t){
		return rep(f,t,-1);
	}

}


import java.util.Arrays;
import java.util.Iterator;
import java.util.PrimitiveIterator;
import java.util.Scanner;
import java.util.function.Supplier;
import java.util.stream.IntStream;
import java.util.stream.Stream;

public class Main{
	static Scanner s=new Scanner(System.in);

	void solve(){
		int n=gInt();
		int[][]score=new int[3][52];
		int[]r= {0,0,0};
		for(int v=0;v<3;++v) {
			int V=v;
			String str=s.next();
			str.chars()
			.map(i->i<'Z'?i-'A':i-'a'+26)
			.forEach(i->++score[V][i]);
			r[v]=Arrays.stream(score[V])
					.map(i->{
						int j=i+n;
						return j<=str.length()?j:j-(str.length()-j)%2;
					})
					.max().getAsInt();
		}

		if(r[0]>r[1]&&r[0]>r[2])
			System.out.println("Kuro");
		else if(r[1]>r[0]&&r[1]>r[2])
			System.out.println("Shiro");
		else if(r[2]>r[0]&&r[2]>r[1])
			System.out.println("Katie");
		else
			System.out.println("Draw");
	}

	public static void main(String[] A){
		new Main().solve();
	}

	static int gInt(){
		return Integer.parseInt(s.next());
	}
	static long gLong(){
		return Long.parseLong(s.next());
	}
	static double gDouble(){
		return Double.parseDouble(s.next());
	}

	SupplyingIterator<Integer> ints(int n){
		return new SupplyingIterator<>(n,Main::gInt);
	}
	SupplyingIterator<Long> longs(int n){
		return new SupplyingIterator<>(n,Main::gLong);
	}
	SupplyingIterator<Double> doubles(int n){
		return new SupplyingIterator<>(n,Main::gDouble);
	}
	SupplyingIterator<String> strs(int n){
		return new SupplyingIterator<>(n,s::next);
	}

	Range rep(int i){
		return Range.rep(i);
	}
	Range rep(int f,int t,int d){
		return Range.rep(f,t,d);
	}
	Range rep(int f,int t){
		return rep(f,t,1);
	}
	Range rrep(int f,int t){
		return rep(t,f,-1);
	}

	IntStream REP(int v){
		return IntStream.range(0,v);
	}
	IntStream REP(int l,int r){
		return IntStream.rangeClosed(l,r);
	}

	IntStream INTS(int n){
		return IntStream.generate(Main::gInt).limit(n);
	}
	Stream<String> STRS(int n){
		return Stream.generate(s::next).limit(n);
	}

}
class SupplyingIterator<T> implements Iterable<T>,Iterator<T>{
	int			t;
	Supplier<T>	supplier;

	SupplyingIterator(int t,Supplier<T> supplier){
		this.t=t;
		this.supplier=supplier;
	}

	@Override
	public Iterator<T> iterator(){
		return this;
	}

	@Override
	public boolean hasNext(){
		return t>0;
	}

	@Override
	public T next(){
		--t;
		return supplier.get();
	}

}
class Range implements Iterable<Integer>,PrimitiveIterator.OfInt{
	int to,cur,d;

	Range(int from,int to,int d){
		this.cur=from-d;
		this.to=to;
		this.d=d;
	}

	Range(int n){
		this(0,n-1,1);
	}

	@Override
	public Iterator<Integer> iterator(){
		return this;
	}

	@Override
	public boolean hasNext(){
		return cur+d==to||(cur!=to&&(cur<to==cur+d<to));
	}

	@Override
	public int nextInt(){
		return cur+=d;
	}

	static Range rep(int i){
		return new Range(i);
	}
	static Range rep(int f,int t,int d){
		return new Range(f,t,d);
	}
	static Range rep(int f,int t){
		return rep(f,t,1);
	}
	static Range rrep(int f,int t){
		return rep(f,t,-1);
	}

}


import java.io.*;
import java.util.*;

public class Mainn {
	InputReader scn;
	PrintWriter out;
	String INPUT = "";

	ArrayList<Integer>[] tree;

	void solve() {
		int n = scn.nextInt(), size;
		char[][] s = { scn.next().toCharArray(), scn.next().toCharArray(), scn.next().toCharArray() };
		int[][] arr = new int[3][200];
		for (int i = 0; i < 3; i++) {
			for (char ch : s[i]) {
				arr[i][ch]--;
			}
			Arrays.sort(arr[i]);
			arr[i][0] *= -1;
		}

		size = s[0].length;

		if (n >= size) {
			out.println("Draw");
			return;
		}

		int[] cnt = new int[3];
		int max = 0;
		for (int i = 0; i < 3; i++) {
			if (n == 1) {
				if (arr[i][0] == size) {
					arr[i][0]--;
				} else {
					arr[i][0]++;
				}
				cnt[i] = arr[i][0];
			} else {
				cnt[i] = Math.min(n + arr[i][0], size);
			}
			max = Math.max(cnt[i], max);
		}

		int ind = -1;
		for (int i = 0, k = 0; i < 3; i++) {
			if (cnt[i] == max) {
				k++;
				ind = i;
			}
			if (k == 2) {
				out.println("Draw");
				return;
			}
		}

		String[] str = { "Kuro", "Shiro", "Katie" };
		out.println(str[ind]);
	}

	void run() throws Exception {
		boolean oj = System.getProperty("ONLINE_JUDGE") != null;
		out = new PrintWriter(System.out);
		scn = new InputReader(oj);
		long time = System.currentTimeMillis();
		solve();
		out.flush();
		if (!oj) {
			System.out.println(Arrays.deepToString(new Object[] { System.currentTimeMillis() - time + " ms" }));
		}
	}

	public static void main(String[] args) throws Exception {
		new Mainn().run();
	}

	public class InputReader {
		InputStream is;

		public InputReader(boolean oj) {
			is = oj ? System.in : new ByteArrayInputStream(INPUT.getBytes());
		}

		byte[] inbuf = new byte[1024];
		public int lenbuf = 0, ptrbuf = 0;

		int readByte() {
			if (lenbuf == -1)
				throw new InputMismatchException();
			if (ptrbuf >= lenbuf) {
				ptrbuf = 0;
				try {
					lenbuf = is.read(inbuf);
				} catch (IOException e) {
					throw new InputMismatchException();
				}
				if (lenbuf <= 0)
					return -1;
			}
			return inbuf[ptrbuf++];
		}

		boolean isSpaceChar(int c) {
			return !(c >= 33 && c <= 126);
		}

		int skip() {
			int b;
			while ((b = readByte()) != -1 && isSpaceChar(b))
				;
			return b;
		}

		double nextDouble() {
			return Double.parseDouble(next());
		}

		char nextChar() {
			return (char) skip();
		}

		String next() {
			int b = skip();
			StringBuilder sb = new StringBuilder();
			while (!(isSpaceChar(b))) { // when nextLine, (isSpaceChar(b) && b != ' ')
				sb.appendCodePoint(b);
				b = readByte();
			}
			return sb.toString();
		}

		char[] next(int n) {
			char[] buf = new char[n];
			int b = skip(), p = 0;
			while (p < n && !(isSpaceChar(b))) {
				buf[p++] = (char) b;
				b = readByte();
			}
			return n == p ? buf : Arrays.copyOf(buf, p);
		}

		char[][] nextMatrix(int n, int m) {
			char[][] map = new char[n][];
			for (int i = 0; i < n; i++)
				map[i] = next(m);
			return map;
		}

		int[] nextArray(int n) {
			int[] a = new int[n];
			for (int i = 0; i < n; i++)
				a[i] = nextInt();
			return a;
		}

		int nextInt() {
			int num = 0, b;
			boolean minus = false;
			while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
				;
			if (b == '-') {
				minus = true;
				b = readByte();
			}

			while (true) {
				if (b >= '0' && b <= '9') {
					num = num * 10 + (b - '0');
				} else {
					return minus ? -num : num;
				}
				b = readByte();
			}
		}

		long nextLong() {
			long num = 0;
			int b;
			boolean minus = false;
			while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
				;
			if (b == '-') {
				minus = true;
				b = readByte();
			}

			while (true) {
				if (b >= '0' && b <= '9') {
					num = num * 10 + (b - '0');
				} else {
					return minus ? -num : num;
				}
				b = readByte();
			}
		}
	}
}


import java.io.*;
import java.util.*;

public class Mainn {
	InputReader scn;
	PrintWriter out;
	String INPUT = "7\r\n" +
			"treasurehunt\r\n" +
			"threefriends\r\n" +
			"hiCodeforces\r\n" +
			"";

	ArrayList<Integer>[] tree;

	void solve() {
		int n = scn.nextInt(), size;
		char[][] s = {scn.next().toCharArray(), scn.next().toCharArray(), scn.next().toCharArray()};
		int[][] arr = new int[3][200];
		for(int i = 0; i < 3; i++) {
			for (char ch : s[i]) {
				arr[i][ch]--;
			}
			Arrays.sort(arr[i]);
			arr[i][0] *= -1;
		}

		size = s[0].length;

		if(n >= size) {
			out.println("Draw");
			return;
		}

		int[] cnt = {arr[0][0], arr[1][0], arr[2][0]};

		for(int i = 0; i < 3; i++) {
			if(size - arr[i][0] <= n) {
				cnt[i] = size;
				continue;
			}
			cnt[i] += n;
		}

		if(cnt[0] > cnt[1] && cnt[0] > cnt[2]) {
			out.println("Kuro");
		} else if(cnt[1] > cnt[0] && cnt[1] > cnt[2]) {
			out.println("Shiro");
		} else if(cnt[2] > cnt[0] && cnt[2] > cnt[1]){
			out.println("Katie");
		} else {
			out.println("Draw");
		}
	}

	void run() throws Exception {
		boolean oj = System.getProperty("ONLINE_JUDGE") != null;
		out = new PrintWriter(System.out);
		scn = new InputReader(oj);
		long time = System.currentTimeMillis();
		solve();
		out.flush();
		if (!oj) {
			System.out.println(Arrays.deepToString(new Object[] { System.currentTimeMillis() - time + " ms" }));
		}
	}

	public static void main(String[] args) throws Exception {
		new Mainn().run();
	}

	public class InputReader {
		InputStream is;

		public InputReader(boolean oj) {
			is = oj ? System.in : new ByteArrayInputStream(INPUT.getBytes());
		}

		byte[] inbuf = new byte[1024];
		public int lenbuf = 0, ptrbuf = 0;

		int readByte() {
			if (lenbuf == -1)
				throw new InputMismatchException();
			if (ptrbuf >= lenbuf) {
				ptrbuf = 0;
				try {
					lenbuf = is.read(inbuf);
				} catch (IOException e) {
					throw new InputMismatchException();
				}
				if (lenbuf <= 0)
					return -1;
			}
			return inbuf[ptrbuf++];
		}

		boolean isSpaceChar(int c) {
			return !(c >= 33 && c <= 126);
		}

		int skip() {
			int b;
			while ((b = readByte()) != -1 && isSpaceChar(b))
				;
			return b;
		}

		double nextDouble() {
			return Double.parseDouble(next());
		}

		char nextChar() {
			return (char) skip();
		}

		String next() {
			int b = skip();
			StringBuilder sb = new StringBuilder();
			while (!(isSpaceChar(b))) { // when nextLine, (isSpaceChar(b) && b != ' ')
				sb.appendCodePoint(b);
				b = readByte();
			}
			return sb.toString();
		}

		char[] next(int n) {
			char[] buf = new char[n];
			int b = skip(), p = 0;
			while (p < n && !(isSpaceChar(b))) {
				buf[p++] = (char) b;
				b = readByte();
			}
			return n == p ? buf : Arrays.copyOf(buf, p);
		}

		char[][] nextMatrix(int n, int m) {
			char[][] map = new char[n][];
			for (int i = 0; i < n; i++)
				map[i] = next(m);
			return map;
		}

		int[] nextArray(int n) {
			int[] a = new int[n];
			for (int i = 0; i < n; i++)
				a[i] = nextInt();
			return a;
		}

		int nextInt() {
			int num = 0, b;
			boolean minus = false;
			while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
				;
			if (b == '-') {
				minus = true;
				b = readByte();
			}

			while (true) {
				if (b >= '0' && b <= '9') {
					num = num * 10 + (b - '0');
				} else {
					return minus ? -num : num;
				}
				b = readByte();
			}
		}

		long nextLong() {
			long num = 0;
			int b;
			boolean minus = false;
			while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
				;
			if (b == '-') {
				minus = true;
				b = readByte();
			}

			while (true) {
				if (b >= '0' && b <= '9') {
					num = num * 10 + (b - '0');
				} else {
					return minus ? -num : num;
				}
				b = readByte();
			}
		}
	}
}


import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.StringTokenizer;
import java.io.IOException;
import java.io.BufferedReader;
import java.util.Comparator;
import java.io.InputStreamReader;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        FastScanner in = new FastScanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskB solver = new TaskB();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskB {
        public void solve(int testNumber, FastScanner in, PrintWriter out) {
            int n = in.nextInt();
            String kuro = in.nextLine();
            String shiro = in.nextLine();
            String katie = in.nextLine();

            int l = kuro.length();
            if (n >= l) {
                out.print("Draw");
                return;
            }
            Temp[] b = new Temp[3];
            b[0] = new Temp(findMax(kuro), 1);
            b[1] = new Temp(findMax(shiro), 2);
            b[2] = new Temp(findMax(katie), 3);

            Arrays.sort(b, Comparator.comparingInt(x -> x.v));
            if (b[2].v == b[1].v) {
                out.print("DRAW");
                return;
            }

            if (b[2].i == 1) {
                out.print("Kuro");
                return;
            }
            if (b[2].i == 2) {
                out.print("Shiro");
                return;
            }
            out.print("Katie");
            return;
        }

        private int findMax(String a) {
            int[] mrk = new int[100];
            Arrays.fill(mrk, 0);
            int l = a.length();
            for (int i = 0; i < l; i++) {
                mrk[a.charAt(i) - '0']++;
            }
            int mx = -1;
            for (int i = 0; i < 100; i++) {
                if (mx < mrk[i]) mx = mrk[i];
            }
            return mx;
        }

        private class Temp {
            int v;
            int i;

            public Temp(int v, int i) {
                this.v = v;
                this.i = i;
            }

        }

    }

    static class FastScanner {
        private BufferedReader bufferedReader;
        private StringTokenizer stringTokenizer;

        public FastScanner(InputStream inputStream) {
            bufferedReader = new BufferedReader(new InputStreamReader(inputStream));
        }

        public String next() {
            if (stringTokenizer == null || !stringTokenizer.hasMoreElements()) {
                try {
                    stringTokenizer = new StringTokenizer(bufferedReader.readLine());
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            return stringTokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public String nextLine() {
            String ret = "";
            try {
                ret = bufferedReader.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            return ret;
        }

    }
}


import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.StringTokenizer;
import java.io.IOException;
import java.io.BufferedReader;
import java.util.Comparator;
import java.io.InputStreamReader;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        FastScanner in = new FastScanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskB solver = new TaskB();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskB {
        public void solve(int testNumber, FastScanner in, PrintWriter out) {
            int n = in.nextInt();
            String[] given = new String[3];
            for (int i = 0; i < 3; i++) {
                given[i] = in.nextLine();
            }

            int l = given[0].length();
            if (n >= l) {
                out.print("Draw");
                return;
            }

            int[][] mrk = new int[3][100];
            for (int i = 0; i < 3; i++) {
                Arrays.fill(mrk[i], 0);
                for (int j = 0; j < l; j++) {
                    mrk[i][given[i].charAt(j) - '0']++;
                }
            }

            int[][] left = new int[3][100];
            for (int i = 0; i < 3; i++) {
                Arrays.fill(left[i], Integer.MAX_VALUE);
                for (int j = 0; j < 100; j++) {
                    int x = l - mrk[i][j];
                    if (x == 0 && n == 1) {
                        left[i][j] = 1;
                    } else if (x >= n) {
                        left[i][j] = x - n;
                    } else {
                        left[i][j] = 0;
                    }
                }
            }
            Temp[] g = new Temp[3];
            for (int i = 0; i < 3; i++) {
                int mn = Integer.MAX_VALUE;
                for (int j = 0; j < 100; j++) {
                    mn = Math.min(mn, left[i][j]);
                }
                g[i] = new Temp(mn, i);
            }

            Arrays.sort(g, Comparator.comparingInt(z -> z.v));
            if (g[0].v == g[1].v) {
                out.print("Draw");
                return;
            }

            if (g[0].i == 0) {
                out.print("Kuro");
                return;
            } else if (g[0].i == 1) {
                out.print("Shiro");
                return;
            }
            out.print("Katie");
            return;
        }

        private class Temp {
            int v;
            int i;

            public Temp(int v, int i) {
                this.v = v;
                this.i = i;
            }

        }

    }

    static class FastScanner {
        private BufferedReader bufferedReader;
        private StringTokenizer stringTokenizer;

        public FastScanner(InputStream inputStream) {
            bufferedReader = new BufferedReader(new InputStreamReader(inputStream));
        }

        public String next() {
            if (stringTokenizer == null || !stringTokenizer.hasMoreElements()) {
                try {
                    stringTokenizer = new StringTokenizer(bufferedReader.readLine());
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            return stringTokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public String nextLine() {
            String ret = "";
            try {
                ret = bufferedReader.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            return ret;
        }

    }
}


import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.StringTokenizer;
import java.io.IOException;
import java.io.BufferedReader;
import java.util.Comparator;
import java.io.InputStreamReader;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        FastScanner in = new FastScanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskB solver = new TaskB();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskB {
        public void solve(int testNumber, FastScanner in, PrintWriter out) {
            int n = in.nextInt();
            String kuro = in.nextLine();
            String shiro = in.nextLine();
            String katie = in.nextLine();

            int l = kuro.length();
            if (n >= l) {
                out.print("Draw");
                return;
            }

            Temp[] b = new Temp[3];
            b[0] = new Temp(leftFinal(l - findMax(kuro), n), 0);
            b[1] = new Temp(leftFinal(l - findMax(shiro), n), 1);
            b[2] = new Temp(leftFinal(l - findMax(katie), n), 2);

            Arrays.sort(b, Comparator.comparingInt(z -> z.v));
            if (b[0].v == b[1].v) {
                out.print("Draw");
                return;
            }

            if (b[0].i == 0) {
                out.print("Kuro");
                return;
            }
            if (b[0].i == 1) {
                out.print("Shiro");
                return;
            }
            out.print("Katie");
        }

        private int findMax(String a) {
            int[] mrk = new int[100];
            Arrays.fill(mrk, 0);
            int l = a.length();
            for (int i = 0; i < l; i++) {
                mrk[a.charAt(i) - '0']++;
            }
            int mx = -1;
            for (int i = 0; i < 100; i++) {
                if (mx < mrk[i]) mx = mrk[i];
            }
            return mx;
        }

        private int leftFinal(int left, int runs) {
            if (runs > left) {
                int runsLeft = runs - left;
                return runsLeft % 2;
            }
            return left - runs;
        }

        private class Temp {
            int v;
            int i;

            public Temp(int v, int i) {
                this.v = v;
                this.i = i;
            }

        }

    }

    static class FastScanner {
        private BufferedReader bufferedReader;
        private StringTokenizer stringTokenizer;

        public FastScanner(InputStream inputStream) {
            bufferedReader = new BufferedReader(new InputStreamReader(inputStream));
        }

        public String next() {
            if (stringTokenizer == null || !stringTokenizer.hasMoreElements()) {
                try {
                    stringTokenizer = new StringTokenizer(bufferedReader.readLine());
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            return stringTokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public String nextLine() {
            String ret = "";
            try {
                ret = bufferedReader.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            return ret;
        }

    }
}


import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.StringTokenizer;
import java.io.IOException;
import java.io.BufferedReader;
import java.util.Comparator;
import java.io.InputStreamReader;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        FastScanner in = new FastScanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskB solver = new TaskB();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskB {
        public void solve(int testNumber, FastScanner in, PrintWriter out) {
            int n = in.nextInt();
            String[] given = new String[3];
            for (int i = 0; i < 3; i++) {
                given[i] = in.nextLine();
            }

            int l = given[0].length();
            if (n >= l) {
                out.print("Draw");
                return;
            }

            int[][] mrk = new int[3][100];
            for (int i = 0; i < 3; i++) {
                Arrays.fill(mrk[i], 0);
                for (int j = 0; j < l; j++) {
                    mrk[i][given[i].charAt(j) - '0']++;
                }
            }

            int[][] left = new int[3][100];
            for (int i = 0; i < 3; i++) {
                Arrays.fill(left[i], Integer.MAX_VALUE);
                for (int j = 0; j < 100; j++) {
                    int x = l - mrk[i][j];
                    if (x >= n) {
                        left[i][j] = x - n;
                    } else {
                        int t = n - x;
                        if (t == 1) left[i][j] = 1;
                        else left[i][j] = 0;
                    }
                }
            }
            Temp[] g = new Temp[3];
            for (int i = 0; i < 3; i++) {
                int mn = Integer.MAX_VALUE;
                for (int j = 0; j < 100; j++) {
                    mn = Math.min(mn, left[i][j]);
                }
                g[i] = new Temp(mn, i);
            }

            Arrays.sort(g, Comparator.comparingInt(z -> z.v));
            if (g[0].v == g[1].v) {
                out.print("Draw");
                return;
            }

            if (g[0].i == 0) {
                out.print("Kuro");
                return;
            } else if (g[0].i == 1) {
                out.print("Shiro");
                return;
            }
            out.print("Katie");
            return;
        }

        private class Temp {
            int v;
            int i;

            public Temp(int v, int i) {
                this.v = v;
                this.i = i;
            }

        }

    }

    static class FastScanner {
        private BufferedReader bufferedReader;
        private StringTokenizer stringTokenizer;

        public FastScanner(InputStream inputStream) {
            bufferedReader = new BufferedReader(new InputStreamReader(inputStream));
        }

        public String next() {
            if (stringTokenizer == null || !stringTokenizer.hasMoreElements()) {
                try {
                    stringTokenizer = new StringTokenizer(bufferedReader.readLine());
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            return stringTokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public String nextLine() {
            String ret = "";
            try {
                ret = bufferedReader.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            return ret;
        }

    }
}


import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.StringTokenizer;
import java.io.IOException;
import java.io.BufferedReader;
import java.util.Comparator;
import java.io.InputStreamReader;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        FastScanner in = new FastScanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskB solver = new TaskB();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskB {
        public void solve(int testNumber, FastScanner in, PrintWriter out) {
            int n = in.nextInt();
            String[] given = new String[3];
            for (int i = 0; i < 3; i++) {
                given[i] = in.nextLine();
            }

            int l = given[0].length();
            if (n >= l) {
                out.print("Draw");
                return;
            }

            int[][] mrk = new int[3][100];
            for (int i = 0; i < 3; i++) {
                Arrays.fill(mrk[i], 0);
                for (int j = 0; j < l; j++) {
                    mrk[i][given[i].charAt(j) - '0']++;
                }
            }

            int[][] left = new int[3][100];
            for (int i = 0; i < 3; i++) {
                Arrays.fill(left[i], Integer.MAX_VALUE);
                for (int j = 0; j < 100; j++) {
                    int x = l - mrk[i][j];
                    if (x >= n) {
                        left[i][j] = x - n;
                    } else {
                        int t = n - x;
                        left[i][j] = t % 2;
                    }
                }
            }
            Temp[] g = new Temp[3];
            for (int i = 0; i < 3; i++) {
                int mn = Integer.MAX_VALUE;
                for (int j = 0; j < 100; j++) {
                    mn = Math.min(mn, left[i][j]);
                }
                g[i] = new Temp(mn, i);
            }

            Arrays.sort(g, Comparator.comparingInt(z -> z.v));
            if (g[0].v == g[1].v) {
                out.print("Draw");
                return;
            }

            if (g[0].i == 0) {
                out.print("Kuro");
                return;
            } else if (g[0].i == 1) {
                out.print("Shiro");
                return;
            }
            out.print("Katie");
            return;
        }

        private class Temp {
            int v;
            int i;

            public Temp(int v, int i) {
                this.v = v;
                this.i = i;
            }

        }

    }

    static class FastScanner {
        private BufferedReader bufferedReader;
        private StringTokenizer stringTokenizer;

        public FastScanner(InputStream inputStream) {
            bufferedReader = new BufferedReader(new InputStreamReader(inputStream));
        }

        public String next() {
            if (stringTokenizer == null || !stringTokenizer.hasMoreElements()) {
                try {
                    stringTokenizer = new StringTokenizer(bufferedReader.readLine());
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            return stringTokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public String nextLine() {
            String ret = "";
            try {
                ret = bufferedReader.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            return ret;
        }

    }
}


import java.io.*;
import java.util.*;

public class Main {

    private static long gcd(long a, long b) {
        return b == 0 ? a : gcd(b, a % b);
    }

    public static void main(String args[]) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        PrintWriter out = new PrintWriter(outputStream);
        InputReader in = new InputReader(inputStream);
        A solver = new A();
        solver.solve(in, out);
        out.close();
    }

    static class A {
        StringBuilder a, b, c;
        Map<Character, Long> mpa, mpb, mpc;

        void solve(InputReader in, PrintWriter out) {
            long n = in.nextLong();
            a = new StringBuilder(in.next());
            b = new StringBuilder(in.next());
            c = new StringBuilder(in.next());
            mpa = new HashMap<>();
            mpb = new HashMap<>();
            mpc = new HashMap<>();

            for (int i = 0, sz = a.length(); i < sz; i++) {
                mpa.computeIfPresent(a.charAt(i), (k, v) -> v + 1);
                mpa.putIfAbsent(a.charAt(i), 1L);
            }
            for (int i = 0, sz = b.length(); i < sz; i++) {
                mpb.computeIfPresent(b.charAt(i), (k, v) -> v + 1);
                mpb.putIfAbsent(b.charAt(i), 1L);
            }
            for (int i = 0, sz = c.length(); i < sz; i++) {
                mpc.computeIfPresent(c.charAt(i), (k, v) -> v + 1);
                mpc.putIfAbsent(c.charAt(i), 1L);
            }
            long[] ans = new long[3];
            ans[0] = beauty(Collections.max(mpa.values()), a.length(), n);
            ans[1] = beauty(Collections.max(mpb.values()), b.length(), n);
            ans[2] = beauty(Collections.max(mpc.values()), c.length(), n);
            if (ans[0] > ans[1] && ans[0] > ans[2]) {
                out.print("Kuro");
            } else if (ans[1] > ans[0] && ans[1] > ans[2]) {
                out.print("Shiro");
            } else if (ans[2] > ans[0] && ans[2] > ans[1]) {
                out.print("Katie");
            } else {
                out.print("Draw");
            }
        }

        long beauty(long max, long size, long turns) {
            long haveToChange = size - max;
            if (turns <= haveToChange) {
                return turns + max;
            }
            if (turns == 1 && max==size) {
                return size - 1;
            }
            return size;
        }

    }

    static class InputReader {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream), 32768);
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public String nextLine() throws IOException {
            if (tokenizer == null)
                return reader.readLine();
            String line = "";
            if (tokenizer.hasMoreTokens())
                line = tokenizer.nextToken("");
            tokenizer = null;
            return line;
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public long nextLong() {
            return Long.parseLong(next());
        }

        public double nextDouble() {
            return Double.parseDouble(next());
        }
    }

}


import java.io.*;
import java.util.*;

public class Main {

    private static long gcd(long a, long b) {
        return b == 0 ? a : gcd(b, a % b);
    }

    public static void main(String args[]) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        PrintWriter out = new PrintWriter(outputStream);
        InputReader in = new InputReader(inputStream);
        A solver = new A();
        solver.solve(in, out);
        out.close();
    }

    static class A {
        StringBuilder a, b, c;
        Map<Character, Long> mpa, mpb, mpc;

        void solve(InputReader in, PrintWriter out) {
            long n = in.nextLong();
            a = new StringBuilder(in.next());
            b = new StringBuilder(in.next());
            c = new StringBuilder(in.next());
            mpa = new HashMap<>();
            mpb = new HashMap<>();
            mpc = new HashMap<>();

            for (int i = 0, sz = a.length(); i < sz; i++) {
                mpa.computeIfPresent(a.charAt(i), (k, v) -> v + 1);
                mpa.putIfAbsent(a.charAt(i), 1L);
            }
            for (int i = 0, sz = b.length(); i < sz; i++) {
                mpb.computeIfPresent(b.charAt(i), (k, v) -> v + 1);
                mpb.putIfAbsent(b.charAt(i), 1L);
            }
            for (int i = 0, sz = c.length(); i < sz; i++) {
                mpc.computeIfPresent(c.charAt(i), (k, v) -> v + 1);
                mpc.putIfAbsent(c.charAt(i), 1L);
            }
            long[] ans = new long[3];
            ans[0] = beauty(Collections.max(mpa.values()), a.length(), n);
            ans[1] = beauty(Collections.max(mpb.values()), b.length(), n);
            ans[2] = beauty(Collections.max(mpc.values()), c.length(), n);
            if (ans[0] > ans[1] && ans[0] > ans[2]) {
                out.print("Kuro");
            } else if (ans[1] > ans[0] && ans[1] > ans[2]) {
                out.print("Shiro");
            } else if (ans[2] > ans[0] && ans[2] > ans[1]) {
                out.print("Katie");
            } else {
                out.print("Draw");
            }
        }

        long beauty(long max, long size, long turns) {
            long haveToChange = size - max;
            if (turns <= haveToChange) {
                return turns + max;
            }
            turns -= haveToChange;
            if (turns % 2 == 1) {
                return size - 1;
            }
            return size;
        }

    }

    static class InputReader {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream), 32768);
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public String nextLine() throws IOException {
            if (tokenizer == null)
                return reader.readLine();
            String line = "";
            if (tokenizer.hasMoreTokens())
                line = tokenizer.nextToken("");
            tokenizer = null;
            return line;
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public long nextLong() {
            return Long.parseLong(next());
        }

        public double nextDouble() {
            return Double.parseDouble(next());
        }
    }

}