# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
1077143 | 2024-08-27T01:42:24 Z | duydzs1tg | Ljeto (COCI21_ljeto) | C++17 | 1 ms | 460 KB |
#include <bits/stdc++.h> #define NAME "CASHIER" #define E <<"\n" #define O <<" "<< #define o <<" " #define se second #define fi first #define ll long long using namespace std; const int MN=1e6+7; const int MOD=1e9+7; int n,z,ans[7] ; vector<int> a[13]; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); if (fopen(NAME ".INP", "r")){ freopen(NAME".INP","r",stdin); freopen(NAME".OUT","w",stdout); } if (fopen(".INP", "r")){ freopen(".INP","r",stdin); freopen(".OUT","w",stdout); } cin>>n; for (int i=1;i<=n;i++) { int t,az,bz; cin>>t>>az>>bz; a[az].push_back(t); } for (int i=1;i<=8;i++) { sort(a[i].begin(),a[i].end()); int jbef=-999; for (int j:a[i]) { ans[i<=4]+=100; if (j-jbef<=10) ans[i<=4]+=50; jbef=j; } } cout<<ans[1] O ans[0]; }
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 348 KB | Output is correct |
2 | Correct | 0 ms | 348 KB | Output is correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 348 KB | Output is correct |
2 | Correct | 0 ms | 348 KB | Output is correct |
3 | Correct | 0 ms | 348 KB | Output is correct |
4 | Correct | 0 ms | 460 KB | Output is correct |
5 | Correct | 1 ms | 344 KB | Output is correct |
6 | Correct | 0 ms | 348 KB | Output is correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 348 KB | Output is correct |
2 | Correct | 0 ms | 348 KB | Output is correct |
3 | Correct | 0 ms | 348 KB | Output is correct |
4 | Correct | 0 ms | 348 KB | Output is correct |
5 | Correct | 0 ms | 348 KB | Output is correct |
6 | Correct | 0 ms | 460 KB | Output is correct |
7 | Correct | 1 ms | 344 KB | Output is correct |
8 | Correct | 0 ms | 348 KB | Output is correct |
9 | Correct | 0 ms | 344 KB | Output is correct |
10 | Correct | 0 ms | 348 KB | Output is correct |
11 | Correct | 0 ms | 348 KB | Output is correct |
12 | Correct | 0 ms | 348 KB | Output is correct |
13 | Correct | 0 ms | 348 KB | Output is correct |