57792023-09-27 16:03:03pyramisZenehallgatáscpp11Wrong answer 0/50284ms13432 KiB
#include <iostream>

using namespace std;

int main()
{
    int N, K;
    int j;
    cin >> N;
    cin >> K;

    int hossz[N];
    int idopontok[K];
    int osszeg = 0;

    int osszegek[10001];

    for(int i = 0; i < N; i++){
        cin >> hossz[i];
    }

    for(int i = 0; i < K; i++){
        cin >> idopontok[i];

    osszeg = 0;
        for( j=0; osszeg<idopontok[i]; j++){
            osszeg = osszeg + hossz[j%N];

            }

                cout << "*"<<j%N <<" ";






        }






    return 0;
}
SubtaskSumTestVerdictTimeMemory
base0/50
1Wrong answer0/03ms1880 KiB
2Time limit exceeded0/0248ms2632 KiB
3Time limit exceeded0/2263ms2216 KiB
4Time limit exceeded0/2272ms3440 KiB
5Time limit exceeded0/2247ms3440 KiB
6Time limit exceeded0/3270ms2800 KiB
7Time limit exceeded0/3280ms3820 KiB
8Time limit exceeded0/3268ms3780 KiB
9Time limit exceeded0/2238ms4592 KiB
10Time limit exceeded0/2284ms5512 KiB
11Time limit exceeded0/2280ms6176 KiB
12Time limit exceeded0/2284ms6776 KiB
13Time limit exceeded0/2252ms7640 KiB
14Time limit exceeded0/2252ms8480 KiB
15Time limit exceeded0/2272ms9072 KiB
16Time limit exceeded0/2268ms9700 KiB
17Time limit exceeded0/2259ms10308 KiB
18Time limit exceeded0/2247ms10940 KiB
19Time limit exceeded0/2266ms11716 KiB
20Time limit exceeded0/2279ms12224 KiB
21Time limit exceeded0/2263ms12540 KiB
22Time limit exceeded0/3256ms12932 KiB
23Time limit exceeded0/3263ms13188 KiB
24Time limit exceeded0/3268ms13432 KiB