Submission #959460

#TimeUsernameProblemLanguageResultExecution timeMemory
959460Bidoneczek11Art Collections (BOI22_art)C++17
Compilation error
0 ms0 KiB
#include <bits/stdc++.h> using namespace std; #define int long long #define ll long long #define ld long double #define pb push_back #define nd second #define st first #define sz size #define forr(i, n) for(int i=1;i<=n;i++) const ll infl=1e18+90; const int inf=1e9+90; vector<int> wek; void solve(int n) { for(int i=1;i<=n;i++) { wek.pb(i); } while(true) { int x=publish(wek); if(x==0) { answer(wek); return; } else { next_permutation(wek.begin(), wek.end()); } } }

Compilation message (stderr)

art.cpp: In function 'void solve(long long int)':
art.cpp:26:15: error: 'publish' was not declared in this scope
   26 |         int x=publish(wek);
      |               ^~~~~~~
art.cpp:29:13: error: 'answer' was not declared in this scope
   29 |             answer(wek);
      |             ^~~~~~
interface.cpp: In function 'int publish(std::vector<int>)':
interface.cpp:20:17: warning: comparison of integer expressions of different signedness: 'std::vector<int>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
   20 |     if(v.size() != N) {
      |        ~~~~~~~~~^~~~
interface.cpp: In function 'void answer(std::vector<int>)':
interface.cpp:36:17: warning: comparison of integer expressions of different signedness: 'std::vector<int>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
   36 |     if(v.size() != N) {
      |        ~~~~~~~~~^~~~