static int count = 1, max = 1;
    public static void main(String[] args) throws IOException {
        List<Integer> list = new ArrayList<>();
        Scanner sc = new Scanner(System.in);
        for (int i = 0; i < 10; i++){
            list.add(sc.nextInt());
        }
        for (int i = 1; i < 10; i++) {
            if (list.get(i).equals(list.get(i - 1))) count++;
            if (max < count) max = count;
            else count = 1;
            }
        System.out.println(max);
    }
}