Submission #974260

#TimeUsernameProblemLanguageResultExecution timeMemory
974260vjudge1Ljeto (COCI21_ljeto)C++17
25 / 50
0 ms348 KiB
#include <bits/stdc++.h> using namespace std; #define int long long #define ll long long #pragma GCC optimize ("O3") #pragma GCC optimize ("unroll-loops") #define fi first #define se second const int MOD = 1e9+7; #define pin pair<int,int> #define lup(i,x) for(int i=0; i<x; i++) #define pb push_back #define pu push #define vint vector<int> #define nitro ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0); #define din(x) int x;cin>>x; #define endl '\n' #define cout std::cout vector<pair<int,pair<int,int>>> p; signed main(){ int n; cin >> n; int elang = 0; int bebek = 0; while(n--){ int t,a,b; cin >> t >> a >> b; for(auto n : p){ if(n.se.fi == a && t-n.fi <= 10 && t-n.fi>=0){ if(a<=4) elang+=50; else bebek+=50; } } p.pb({t,{a,b}}); if(a<=4) elang+=100; else bebek+=100; } cout << elang << " " << bebek << endl; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...