67412023-12-18 13:04:37madvirKéséscpp17Wrong answer 16/50259ms21948 KiB
#include <iostream>
#include <set>

using namespace std;

int main()
{
    unsigned int n, minp=0;
    cin >> n;
    int a[n];
    set<int> evek;

    for(unsigned int i=0; i<n; i++) {
        cin >> a[i];
        evek.insert(a[i]);
    }
    minp=evek.size();
    evek.clear();
    int z=n;
    while(evek.size()<minp) {
        evek.insert(a[z]);
        z--;
    }
    cout << ++z;
    return 0;
}
SubtaskSumTestVerdictTimeMemory
base16/50
1Accepted0/03ms1684 KiB
2Wrong answer0/014ms2840 KiB
3Wrong answer0/53ms2148 KiB
4Wrong answer0/53ms2176 KiB
5Wrong answer0/564ms4080 KiB
6Wrong answer0/564ms4288 KiB
7Wrong answer0/4200ms16176 KiB
8Accepted4/4202ms15980 KiB
9Accepted4/4180ms14492 KiB
10Accepted4/4170ms13548 KiB
11Wrong answer0/4156ms12228 KiB
12Wrong answer0/2200ms13060 KiB
13Wrong answer0/2259ms21948 KiB
14Accepted1/1246ms21728 KiB
15Accepted1/1241ms21556 KiB
16Accepted1/1212ms18176 KiB
17Accepted1/1192ms14192 KiB
18Wrong answer0/1128ms6308 KiB
19Wrong answer0/1118ms5544 KiB