74382024-01-09 08:36:28CsongiAranycipők (45)csharpAccepted 45/4532ms23104 KiB
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace r
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = int.Parse(Console.ReadLine());
            int legnagyobb = 0;
            int[] golok = new int[n];
            for (int i = 0; i < n; i++)
            {
                
                golok[i] = int.Parse(Console.ReadLine());
                if (golok[i] > legnagyobb)
                {
                    legnagyobb = golok[i];
                }
                    
            }
            Console.WriteLine(legnagyobb);
            List<int> list = new List<int>(n);
            for (int i = 0; i < golok.Length; i++)
            {
                if (golok[i] == legnagyobb)
                    list.Add(i + 1);
            }
            Console.WriteLine(list.Count);
            foreach (int i in list)
            {
                Console.WriteLine(i);
            }
            Console.ReadKey();
        }
    }
}
SubtaskSumTestVerdictTimeMemory
base45/45
1Accepted0/027ms20404 KiB
2Accepted0/028ms20656 KiB
3Accepted3/327ms21144 KiB
4Accepted3/327ms21512 KiB
5Accepted3/327ms21488 KiB
6Accepted3/327ms21728 KiB
7Accepted3/327ms21620 KiB
8Accepted3/327ms21468 KiB
9Accepted3/328ms21772 KiB
10Accepted3/330ms21976 KiB
11Accepted3/328ms22224 KiB
12Accepted3/328ms22304 KiB
13Accepted3/328ms22596 KiB
14Accepted3/329ms22860 KiB
15Accepted3/332ms23028 KiB
16Accepted3/328ms22620 KiB
17Accepted3/329ms23104 KiB