57652023-09-21 08:22:57zsebiAranycipők (45)cpp11Elfogadva 45/453ms3908 KiB
// aranycipok.cpp : This file contains the 'main' function. Program execution begins and ends there.
//

#include <iostream>
#include <queue>

#define ll long long 
using namespace std;
ll n;
int main()
{
    cin >> n;
    vector<ll>x(n),ans;
    ll maxi = -1,db=0;
    for (int i = 0; i < n; ++i)
    {
        cin >> x[i];
        if (x[i] > maxi)maxi = x[i];
    }
    for (int i = 0; i < n; ++i)
    {
        if (x[i] == maxi)
        {
             db++;
             ans.push_back(i + 1);
        }
    }
    cout << maxi << "\n" << db<<"\n";
    for (auto& e : ans)cout << e << "\n";

    return 0;
}

// Run program: Ctrl + F5 or Debug > Start Without Debugging menu
// Debug program: F5 or Debug > Start Debugging menu

// Tips for Getting Started: 
//   1. Use the Solution Explorer window to add/manage files
//   2. Use the Team Explorer window to connect to source control
//   3. Use the Output window to see build output and other messages
//   4. Use the Error List window to view errors
//   5. Go to Project > Add New Item to create new code files, or Project > Add Existing Item to add existing code files to the project
//   6. In the future, to open this project again, go to File > Open > Project and select the .sln file
RészfeladatÖsszpontTesztVerdiktIdőMemória
base45/45
1Elfogadva0/03ms1808 KiB
2Elfogadva0/03ms2068 KiB
3Elfogadva3/32ms2268 KiB
4Elfogadva3/32ms2324 KiB
5Elfogadva3/32ms2404 KiB
6Elfogadva3/33ms2528 KiB
7Elfogadva3/33ms2744 KiB
8Elfogadva3/33ms2956 KiB
9Elfogadva3/33ms3164 KiB
10Elfogadva3/33ms3444 KiB
11Elfogadva3/33ms3360 KiB
12Elfogadva3/33ms3324 KiB
13Elfogadva3/33ms3328 KiB
14Elfogadva3/33ms3456 KiB
15Elfogadva3/33ms3544 KiB
16Elfogadva3/33ms3680 KiB
17Elfogadva3/33ms3908 KiB