142692025-01-10 11:17:39250L7Aranycipők (45)csharpRuntime error 0/4514ms2872 KiB
using System;
using System.Collections.Generic;

namespace new_golden_shoe
{
    class Program
    {
        static void Main(string[] args)
        {
            int N = Convert.ToInt32(Console.ReadLine());
            int[] J = new int[N];
            for (int i = 0; i < N; i++)
            {
                J[i] = Convert.ToInt32(Console.ReadLine());
            }
            int max = 0; int Nmax = 0;
            List<int> A = new List<int>();
            for (int i = 0; i < N; i++)
            {
                if (max < J[i])
                {
                    max = J[i];
                    A.Clear();
                    A.Add(i + 1);
                }
                else if (max == J[i])
                {
                    A.Add(i + 1);
                }
            }
            Console.WriteLine(max);
            Console.WriteLine(A.Count);
            for (int i = 0; i < A.Count; i++)
            {
                Console.WriteLine(A[i]);
            }






            Console.ReadKey();
        }
    }
}
SubtaskSumTestVerdictTimeMemory
base0/45
1Runtime error0/014ms2836 KiB
2Runtime error0/014ms2764 KiB
3Runtime error0/314ms2780 KiB
4Runtime error0/314ms2556 KiB
5Runtime error0/314ms2552 KiB
6Runtime error0/314ms2528 KiB
7Runtime error0/313ms2864 KiB
8Runtime error0/314ms2772 KiB
9Runtime error0/314ms2800 KiB
10Runtime error0/314ms2776 KiB
11Runtime error0/314ms2648 KiB
12Runtime error0/314ms2700 KiB
13Runtime error0/314ms2676 KiB
14Runtime error0/314ms2524 KiB
15Runtime error0/314ms2656 KiB
16Runtime error0/314ms2844 KiB
17Runtime error0/314ms2872 KiB