import java.util.Scanner;
import java.util.TreeMap;
import java.util.Map;

public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        TreeMap<String,Integer> hm = new TreeMap<String,Integer>();
        int max = 0;
        for(int i = 0; i < a; i++){
            String str = sc.next();
            if(hm.containsKey(str)){
                hm.put(str, hm.get(str) + 1);
            }else{
                hm.put(str, 1);
            }
            if(max < hm.get(str)){
                max = hm.get(str);
            }
        }
        for(Map.Entry<String,Integer> e : hm.entrySet()){
            if(max == e.getValue()){
                System.out.println(e.getKey());
            }
        }
    }
} import java.util.Scanner; Scanner java.util import java.util.TreeMap; TreeMap java.util import java.util.Map; Map java.util public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        TreeMap<String,Integer> hm = new TreeMap<String,Integer>();
        int max = 0;
        for(int i = 0; i < a; i++){
            String str = sc.next();
            if(hm.containsKey(str)){
                hm.put(str, hm.get(str) + 1);
            }else{
                hm.put(str, 1);
            }
            if(max < hm.get(str)){
                max = hm.get(str);
            }
        }
        for(Map.Entry<String,Integer> e : hm.entrySet()){
            if(max == e.getValue()){
                System.out.println(e.getKey());
            }
        }
    }
} Main public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        TreeMap<String,Integer> hm = new TreeMap<String,Integer>();
        int max = 0;
        for(int i = 0; i < a; i++){
            String str = sc.next();
            if(hm.containsKey(str)){
                hm.put(str, hm.get(str) + 1);
            }else{
                hm.put(str, 1);
            }
            if(max < hm.get(str)){
                max = hm.get(str);
            }
        }
        for(Map.Entry<String,Integer> e : hm.entrySet()){
            if(max == e.getValue()){
                System.out.println(e.getKey());
            }
        }
    } main {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        TreeMap<String,Integer> hm = new TreeMap<String,Integer>();
        int max = 0;
        for(int i = 0; i < a; i++){
            String str = sc.next();
            if(hm.containsKey(str)){
                hm.put(str, hm.get(str) + 1);
            }else{
                hm.put(str, 1);
            }
            if(max < hm.get(str)){
                max = hm.get(str);
            }
        }
        for(Map.Entry<String,Integer> e : hm.entrySet()){
            if(max == e.getValue()){
                System.out.println(e.getKey());
            }
        }
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc TreeMap<String,Integer> hm = new TreeMap<String,Integer>(); hm new TreeMap<String,Integer>() int max = 0; max 0 for(int i = 0; i < a; i++){
            String str = sc.next();
            if(hm.containsKey(str)){
                hm.put(str, hm.get(str) + 1);
            }else{
                hm.put(str, 1);
            }
            if(max < hm.get(str)){
                max = hm.get(str);
            }
        } int i = 0; int i = 0; i 0 i < a i a i++ i++ i {
            String str = sc.next();
            if(hm.containsKey(str)){
                hm.put(str, hm.get(str) + 1);
            }else{
                hm.put(str, 1);
            }
            if(max < hm.get(str)){
                max = hm.get(str);
            }
        } {
            String str = sc.next();
            if(hm.containsKey(str)){
                hm.put(str, hm.get(str) + 1);
            }else{
                hm.put(str, 1);
            }
            if(max < hm.get(str)){
                max = hm.get(str);
            }
        } String str = sc.next(); str sc.next() sc.next sc if(hm.containsKey(str)){
                hm.put(str, hm.get(str) + 1);
            }else{
                hm.put(str, 1);
            } hm.containsKey(str) hm.containsKey hm str {
                hm.put(str, hm.get(str) + 1);
            } hm.put(str, hm.get(str) + 1) hm.put hm str hm.get(str) + 1 hm.get(str) hm.get hm str 1 {
                hm.put(str, 1);
            } hm.put(str, 1) hm.put hm str 1 if(max < hm.get(str)){
                max = hm.get(str);
            } max < hm.get(str) max hm.get(str) hm.get hm str {
                max = hm.get(str);
            } max = hm.get(str) max hm.get(str) hm.get hm str for(Map.Entry<String,Integer> e : hm.entrySet()){
            if(max == e.getValue()){
                System.out.println(e.getKey());
            }
        } Map.Entry<String,Integer> e hm.entrySet() hm.entrySet hm {
            if(max == e.getValue()){
                System.out.println(e.getKey());
            }
        } {
            if(max == e.getValue()){
                System.out.println(e.getKey());
            }
        } if(max == e.getValue()){
                System.out.println(e.getKey());
            } max == e.getValue() max e.getValue() e.getValue e {
                System.out.println(e.getKey());
            } System.out.println(e.getKey()) System.out.println System.out System System.out e.getKey() e.getKey e String[] args args public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        TreeMap<String,Integer> hm = new TreeMap<String,Integer>();
        int max = 0;
        for(int i = 0; i < a; i++){
            String str = sc.next();
            if(hm.containsKey(str)){
                hm.put(str, hm.get(str) + 1);
            }else{
                hm.put(str, 1);
            }
            if(max < hm.get(str)){
                max = hm.get(str);
            }
        }
        for(Map.Entry<String,Integer> e : hm.entrySet()){
            if(max == e.getValue()){
                System.out.println(e.getKey());
            }
        }
    }
} public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        TreeMap<String,Integer> hm = new TreeMap<String,Integer>();
        int max = 0;
        for(int i = 0; i < a; i++){
            String str = sc.next();
            if(hm.containsKey(str)){
                hm.put(str, hm.get(str) + 1);
            }else{
                hm.put(str, 1);
            }
            if(max < hm.get(str)){
                max = hm.get(str);
            }
        }
        for(Map.Entry<String,Integer> e : hm.entrySet()){
            if(max == e.getValue()){
                System.out.println(e.getKey());
            }
        }
    }
} Main
import java.util.Scanner;
import java.util.TreeMap;
import java.util.Map;

public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        TreeMap<String,Integer> hm = new TreeMap<String,Integer>();
        int max = 0;
        for(int i = 0; i < a; i++){
            String str = sc.next();
            if(hm.containsKey(str)){
                hm.put(str, hm.get(str) + 1);
            }else{
                hm.put(str, 1);
            }
            if(max < hm.get(str)){
                max = hm.get(str);
            }
        }
        for(Map.Entry<String,Integer> e : hm.entrySet()){
            if(max == e.getValue()){
                System.out.println(e.getKey());
            }
        }
    }
}
