# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
100975 | 2019-03-15T15:38:33 Z | KLPP | Wand (COCI19_wand) | C++14 | 53 ms | 2304 KB |
#include<bits/stdc++.h> using namespace std; typedef long long int lld; int main(){ int n,m; scanf("%d %d",&n,&m); int victory[n]; int fail[n]; for(int i=0;i<n;i++){ victory[i]=0; fail[i]=0; } for(int i=0;i<m;i++){ int x,y; scanf("%d %d",&x,&y); x--;y--; victory[x]++; fail[y]++; } for(int i=0;i<n;i++){ if(victory[i]>0 || (victory[i]+fail[i]==0)){ cout<<1; }else cout<<0; }cout<<endl; return 0; }
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Incorrect | 3 ms | 384 KB | Output isn't correct |
2 | Correct | 2 ms | 384 KB | Output is correct |
3 | Incorrect | 34 ms | 2168 KB | Output isn't correct |
4 | Incorrect | 36 ms | 2168 KB | Output isn't correct |
5 | Incorrect | 42 ms | 2132 KB | Output isn't correct |
6 | Incorrect | 32 ms | 2176 KB | Output isn't correct |
7 | Incorrect | 53 ms | 2168 KB | Output isn't correct |
8 | Incorrect | 49 ms | 2168 KB | Output isn't correct |
9 | Incorrect | 34 ms | 2300 KB | Output isn't correct |
10 | Incorrect | 40 ms | 2304 KB | Output isn't correct |