Submission #638945

#TimeUsernameProblemLanguageResultExecution timeMemory
638945MatheusLealVLjeto (COCI21_ljeto)C++17
50 / 50
1 ms316 KiB
#include <bits/stdc++.h> using namespace std; int n, last[10],L,R; int main(){ ios::sync_with_stdio(false); cin.tie(0); cin>>n; memset(last, -1, sizeof last); for(int i = 1, t,a,b; i <= n; i++){ cin>>t>>a>>b; if(a <= 4) L += 100; else R += 100; if(last[a] != -1 and t - last[a] <= 10){ if(a <= 4) L += 50; else R += 50; } last[a]=t; } cout<<L<<" "<<R<<"\n"; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...