# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
726804 | kerem | ACM (COCI19_acm) | C++14 | 2 ms | 568 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define pb push_back
#define fir first
#define sec second
#define fast ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);
int32_t main(){
fast;
int n,m;
vector<pair<int,pair<int,string>>> v;
cin >> n >> m;
for(int i=0;i<=n;i++){
string s;
int x=0,y=0;
cin >> s;
for(int j=0;j<m;j++){
string t;
cin >> t;
if(t=="-")
continue;
if(t[0]!='-'){
x++;
y+=(s[1]-49)*2000;
}
if(t.size()>2)
y+=(t[3]-48)*100000+(t[4]-48)*10000+(t[6]-48)*1000+(t[7]-48)*100+(t[9]-48)*10+(t[10]-48);
}
if(s!="NijeZivotJedanACM" or i==n)
v.pb({-x,{y,s}});
}
sort(v.begin(),v.end());
for(int i=0;i<v.size();i++){
if(v[i].sec.sec=="NijeZivotJedanACM"){
cout << i+1;
return 0;
}
}
return 0;
}
컴파일 시 표준 에러 (stderr) 메시지
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |