235802026-01-25 17:17:54BalázsFasor (40)cpp17Wrong answer 22/4071ms1972 KiB
#include <iostream>
#include<bits/stdc++.h>

using namespace std;

int main()
{
    int jelenlegi=0;
    int n,k;
    cin>>n>>k;
    vector<long long>fasor(n);
        for (int i=0; i<n; i++){
            cin>>fasor[i];
        }
    for(int i=jelenlegi+1; i<=k; i++){
        if(fasor[i]>fasor[jelenlegi]){
            jelenlegi=i;
            i=jelenlegi+1;
        }
    }
   cout<<jelenlegi+1;
    return 0;
}
SubtaskSumTestVerdictTimeMemory
base22/40
1Accepted0/01ms316 KiB
2Wrong answer0/04ms316 KiB
3Accepted2/21ms316 KiB
4Wrong answer0/21ms316 KiB
5Accepted2/21ms316 KiB
6Wrong answer0/21ms316 KiB
7Accepted2/21ms316 KiB
8Wrong answer0/22ms316 KiB
9Accepted2/24ms472 KiB
10Wrong answer0/24ms316 KiB
11Wrong answer0/24ms340 KiB
12Accepted2/23ms316 KiB
13Wrong answer0/235ms1196 KiB
14Runtime error0/234ms1192 KiB
15Accepted2/254ms1972 KiB
16Accepted2/265ms1852 KiB
17Accepted2/271ms1844 KiB
18Wrong answer0/271ms1972 KiB
19Wrong answer0/271ms1844 KiB
20Accepted2/220ms1076 KiB
21Accepted2/257ms1844 KiB
22Accepted2/271ms1844 KiB