제출 #837235

#제출 시각아이디문제언어결과실행 시간메모리
837235Sohsoh84수천개의 섬 (IOI22_islands)C++17
0 / 100
32 ms48092 KiB
#include "islands.h" #include <bits/stdc++.h> using namespace std; const int MAXN = 1e6 + 10; int deg[MAXN], n, m; vector<int> f[MAXN]; variant<bool, vector<int>> find_journey(int n_, int m_, vector<int> U_, vector<int> V_) { n = n_; m = m_; for (int i = 0; i < m; i++) deg[U_[i]]++, f[MAXN]; if (deg[0] >= 2 && deg[1] >= 1) return vector<int>({f[0][0], f[1][0], f[0][1], f[0][0], f[1][0], f[0][1]}); return false; }

컴파일 시 표준 에러 (stderr) 메시지

islands.cpp: In function 'std::variant<bool, std::vector<int, std::allocator<int> > > find_journey(int, int, std::vector<int>, std::vector<int>)':
islands.cpp:14:50: warning: right operand of comma operator has no effect [-Wunused-value]
   14 |  for (int i = 0; i < m; i++) deg[U_[i]]++, f[MAXN];
      |                                            ~~~~~~^
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...