232612026-01-16 21:44:19helloworldAranycipők (45)cpp17Accepted 45/451ms332 KiB
#include <iostream>
#include <algorithm>
using namespace std;

int main()
{
    int N;
    cin>>N;
    int golok[N+1];
    int a;
    int maximum=-1;
    int db=0;
    for(int i=1; i<=N; i++){
        cin>>golok[i];
        maximum=max(golok[i], maximum);
    }
    cout<<maximum<<"\n";
    for(int i=1; i<=N; i++){
        if(golok[i]==maximum)db++;
    }
    cout<<db<<"\n";
    for(int i=1; i<=N; i++){
        if(golok[i]==maximum)cout<<i<<"\n";
    }
    return 0;
}
SubtaskSumTestVerdictTimeMemory
base45/45
1Accepted0/01ms316 KiB
2Accepted0/01ms316 KiB
3Accepted3/31ms316 KiB
4Accepted3/31ms316 KiB
5Accepted3/31ms316 KiB
6Accepted3/31ms316 KiB
7Accepted3/31ms316 KiB
8Accepted3/31ms316 KiB
9Accepted3/31ms316 KiB
10Accepted3/31ms316 KiB
11Accepted3/31ms332 KiB
12Accepted3/31ms316 KiB
13Accepted3/31ms316 KiB
14Accepted3/31ms316 KiB
15Accepted3/31ms316 KiB
16Accepted3/31ms316 KiB
17Accepted3/31ms316 KiB