Submission #499399

# Submission time Handle Problem Language Result Execution time Memory
499399 2021-12-28T11:00:20 Z adam Ljeto (COCI21_ljeto) C++14
25 / 50
1 ms 204 KB
#include <iostream>

using namespace std;

int main()
{
    int n;
    cin>>n;
    int sum1=0,sum2=0;
    int a[n],b[n],c[n];
    for(int i=0;i<n;i++){
        cin>>a[i]>>b[i]>>c[i];

        if(a[i]-a[i-1]<=10&&b[i]==b[i-1]&&b[i]>=5)sum2+=50;
        if((a[i]-a[i-1]<=10&&b[i]==b[i-1]&&b[i]<5))sum1+=50;
        if(b[i]<5)sum1+=100;
        if(b[i]>=5)sum2+=100;
    }
    cout<<sum1<<' '<<sum2;
    return 0;
}
# Verdict Execution time Memory Grader output
1 Correct 0 ms 204 KB Output is correct
2 Correct 1 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 0 ms 204 KB Output is correct
2 Correct 0 ms 204 KB Output is correct
3 Correct 0 ms 204 KB Output is correct
4 Correct 0 ms 204 KB Output is correct
5 Correct 0 ms 204 KB Output is correct
6 Correct 1 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 0 ms 204 KB Output is correct
2 Correct 1 ms 204 KB Output is correct
3 Correct 0 ms 204 KB Output is correct
4 Correct 0 ms 204 KB Output is correct
5 Correct 0 ms 204 KB Output is correct
6 Correct 0 ms 204 KB Output is correct
7 Correct 0 ms 204 KB Output is correct
8 Correct 1 ms 204 KB Output is correct
9 Correct 1 ms 204 KB Output is correct
10 Correct 1 ms 204 KB Output is correct
11 Incorrect 1 ms 204 KB Output isn't correct
12 Halted 0 ms 0 KB -