# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
1006423 | kebine | 게임 (IOI14_game) | C++17 | 0 ms | 0 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
using namespace std;
#pragma GCC optimize("Ofast")
#pragma GCC optimize("unroll-loops")
#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
typedef long long ll;
const ll INF = 1e9;
const ll MOD = 998244353;
const ll MAXN = 2e5 + 5;
const ll LOG = 30;
#define vll vector <ll>
#define pll pair <ll, ll>
#define fi first
#define se second
#define endl '\n'
#define lc (pos+1)
#define rc (pos+2*(mid-l+1))
#define mid ((l+r)/2)
ll n, m, d;
ll a [MAXN];
void solve(){
cin >> n;
for(ll i = 1; i <= (n*(n-1))/2; i++){
ll x, y; cin >> x >> y;
a[x]++, a[y]++;
if(a[x] == n-1 || a[y] == n-1) cout << "yes" << endl;
else cout << "no" << endl;
}
}
int main(){
ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0);
// ll t; cin >> t;
// while(t--){
solve();
// }
}