124562024-12-18 09:33:47feheristvanHőségriadó (50 pont)cpp17Wrong answer 6/5021ms560 KiB
#include <iostream>
#include <vector>

using namespace std;

int main()
{
    int n, k, l, f;
    cin >> n >> k >> l >> f;
    int folotte = 0, alatta = 0, x;
    int hosegriado = 0;
    for(int i = 0; i < n; i ++){
        cin >> x;
        if(x >= f)
            folotte ++;
        else if(x < f){
            alatta ++;
        }
        if(alatta == l){
            folotte = 0;
            alatta = 0;
        }
        if(folotte == k){
            hosegriado ++;
        }
    }
    cout << hosegriado;
    return 0;
}
SubtaskSumTestVerdictTimeMemory
base6/50
1Accepted0/01ms508 KiB
2Wrong answer0/021ms320 KiB
3Accepted2/21ms560 KiB
4Accepted2/21ms320 KiB
5Accepted2/21ms320 KiB
6Wrong answer0/21ms508 KiB
7Wrong answer0/21ms320 KiB
8Wrong answer0/41ms320 KiB
9Wrong answer0/48ms408 KiB
10Wrong answer0/410ms408 KiB
11Wrong answer0/414ms504 KiB
12Wrong answer0/412ms320 KiB
13Wrong answer0/417ms404 KiB
14Wrong answer0/42ms320 KiB
15Wrong answer0/420ms408 KiB
16Wrong answer0/419ms404 KiB
17Wrong answer0/420ms408 KiB