제출 #1059223

#제출 시각아이디문제언어결과실행 시간메모리
1059223vjudge1게임 (IOI14_game)C++17
0 / 100
0 ms600 KiB
#include "game.h" #include <bits/stdc++.h> using namespace std; #define ll long long #define pb push_back const int INF=100000000; int memoria[2000][2000]; vector<int> posiblesarist; void initialize(int n) { for(int i=0;i<n;i++){ posiblesarist.pb(n-1); } } int hasEdge(int u, int v) { if(memoria[u][v]==1){ return 1; } //cout<<posiblesarist[u]<<" POSIBLEARISTA U"<<endl; //cout<<posiblesarist[v]<<" POSIBLEARISTA V"<<endl; if(posiblesarist[u]>1 && posiblesarist[v]>1){ posiblesarist[u]--; posiblesarist[v]--; return 0; }else{ memoria[u][v]=1; memoria[v][u]=1; posiblesarist[u]--; posiblesarist[v]--; //posiblesarist[u]=INF; //posiblesarist[v]=INF; return 1; } return 1; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...