# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
875826 | 2023-11-20T14:59:42 Z | BbtT | Vudu (COCI15_vudu) | C++17 | 1000 ms | 17704 KB |
#include<bits/stdc++.h> using namespace std; long long int N,P,a[1000001]; int main(){ long long int C=0; cin>>N; for(int i=1;i<=N;i++){ int temp; scanf("%d",&temp); a[i]=a[i-1]+temp; } cin>>P; for(int i=1;i<=N;i++){ for(int j=i;j<=N;j++){ if(a[j]-a[i-1]>=P*(j-i+1))C++; } }cout<<C<<endl; return 0; }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 26 ms | 348 KB | Output is correct |
2 | Correct | 15 ms | 344 KB | Output is correct |
3 | Correct | 15 ms | 348 KB | Output is correct |
4 | Execution timed out | 1058 ms | 17244 KB | Time limit exceeded |
5 | Execution timed out | 1064 ms | 9812 KB | Time limit exceeded |
6 | Execution timed out | 1035 ms | 15192 KB | Time limit exceeded |
7 | Execution timed out | 1044 ms | 16340 KB | Time limit exceeded |
8 | Execution timed out | 1016 ms | 14164 KB | Time limit exceeded |
9 | Execution timed out | 1047 ms | 17704 KB | Time limit exceeded |
10 | Execution timed out | 1057 ms | 15448 KB | Time limit exceeded |