제출 #429669

#제출 시각아이디문제언어결과실행 시간메모리
429669schseHandcrafted Gift (IOI20_gift)C++17
10 / 100
171 ms20804 KiB
#include "gift.h" #include <bits/stdc++.h> using namespace std; #ifndef EVAL #include "grader.cpp" #endif int construct(int n, int r, std::vector<int> a, std::vector<int> b, std::vector<int> x) { int sb = 0; for (int i : x) sb |= i; if (sb == 1) { std::string s(n, 'R'); craft(s); return 1; } else if (sb == 2) { std::string s(n, 'R'); for (int i = 0; i < n; i++) s[i] = i % 2 ? 'R' : 'B'; craft(s); return 1; } else { } }

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

gift.cpp: In function 'int construct(int, int, std::vector<int>, std::vector<int>, std::vector<int>)':
gift.cpp:32:1: warning: control reaches end of non-void function [-Wreturn-type]
   32 | }
      | ^
#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...