Submission #965254

#TimeUsernameProblemLanguageResultExecution timeMemory
965254willychanAncient Machine 2 (JOI23_ancient2)C++17
10 / 100
85 ms1764 KiB
#include "ancient2.h" #include<bits/stdc++.h> using namespace std; namespace { int variable_example = 1; } // namespace std::string Solve(int N) { int B = N+1; string ans=""; for(int i=1;i<B;i++){ int m = i+2; vector<int> a(m); vector<int> b(m); for(int j=0;j<i-1;j++){ a[j]=j+1; b[j]=j+1; } a[i-1] = i; b[i-1] = i+1; a[i]=i; b[i]=i; a[i+1]=i+1; b[i+1]=i+1; int k = Query(m,a,b); if(k==i) ans.push_back('0'); else ans.push_back('1'); } return ans; }

Compilation message (stderr)

ancient2.cpp:6:5: warning: '{anonymous}::variable_example' defined but not used [-Wunused-variable]
    6 | int variable_example = 1;
      |     ^~~~~~~~~~~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...