Submission #691880

# Submission time Handle Problem Language Result Execution time Memory
691880 2023-01-31T20:47:58 Z Elvin_Fritl Ljeto (COCI21_ljeto) C++17
10 / 50
1 ms 256 KB
#include <bits/stdc++.h>
#define int int64_t
#define ll int128_t
using namespace std;

int32_t main()
{
    int T,sayp=0,sayg=0;
    cin>>T;
    int p=-10,g=-10;
    while(T--){
        int t,r,s;
        cin>>t>>r>>s;
        if(r<5){
            sayp+=100;
            if(t-p<=10){
                sayp+=50;
            }
            p=t;
        }
        else{
            sayg+=100;
            if(t-g<=10){
                sayg+=50;
            }
            g=t;
        }
    }
    cout<<sayp<<" "<<sayg;


    return 0;
}
# Verdict Execution time Memory Grader output
1 Correct 0 ms 212 KB Output is correct
2 Correct 1 ms 212 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 256 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 212 KB Output is correct
2 Correct 1 ms 212 KB Output is correct
3 Incorrect 1 ms 256 KB Output isn't correct
4 Halted 0 ms 0 KB -