150842025-02-12 13:45:13markfsibianKéséscpp17Wrong answer 0/50234ms8756 KiB
// keses.cpp : This file contains the 'main' function. Program execution begins and ends there.
//

#include <iostream>
#include <map>
#include <algorithm>
#include <climits>

using namespace std;
map<int, int> v;

int main()
{
    int n;
    cin >> n;
    int t;
    for (int i = 1; i <= n; ++i)
    {
        cin >> t;
        v.insert_or_assign(t, i);
    }

    int maxi = INT_MAX;
    for (auto& e : v)
        if (maxi > e.second)
            maxi = e.second;

    cout << maxi + 1;
}

// 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
SubtaskSumTestVerdictTimeMemory
base0/50
1Wrong answer0/01ms316 KiB
2Wrong answer0/010ms564 KiB
3Wrong answer0/52ms316 KiB
4Wrong answer0/52ms508 KiB
5Wrong answer0/564ms316 KiB
6Wrong answer0/564ms512 KiB
7Wrong answer0/4157ms6136 KiB
8Wrong answer0/4156ms5928 KiB
9Wrong answer0/4151ms5176 KiB
10Wrong answer0/4148ms4660 KiB
11Wrong answer0/4137ms3892 KiB
12Wrong answer0/2166ms4252 KiB
13Wrong answer0/2234ms8756 KiB
14Wrong answer0/1231ms8500 KiB
15Wrong answer0/1203ms8496 KiB
16Wrong answer0/1194ms6820 KiB
17Wrong answer0/1168ms4660 KiB
18Wrong answer0/1126ms812 KiB
19Wrong answer0/1119ms580 KiB