# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
86357 | Asag | Telefoni (COCI17_telefoni) | C++14 | 60 ms | 1916 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
using namespace std;
int n , m ,ans,cnt,a[300000 + 5],sum,num[300000 + 5];
int main()
{
cin>>n>>m;
for(int i = 1; i <= n ;i ++)
{
cin>>a[i];
if(!a[i])
{
cnt++;
}else
{
ans+=cnt / m;
cnt = 0;
}
}cout<<ans;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |