Submission #444046

# Submission time Handle Problem Language Result Execution time Memory
444046 2021-07-13T03:58:26 Z yungyao The Collection Game (BOI21_swaps) C++17
0 / 100
0 ms 200 KB
    using namespace std;
    #include <iostream>
    #include <algorithm>
    #include <queue>
    #include <stack>
    #include <map>
    #include <set>
    #include <utility>
    #include <vector>
    #include <memory.h>

    typedef long long LL;
    typedef pair<int,int> pii;
    #define F first
    #define S second
    #define mkp make_pair
    #define iter(x) x.begin(),x.end()
    #define MEM(s,e) memset(s,e,sizeof(s))

    const int maxn = 0;
    #include <swaps.h>
    #include <assert.h>

    void solve(int n,int v){
        int a[300];
        int cnt = 0;
        for (int i=1;i<n;++i){
            for (int j=n-1;j>=i;--j){
                schedule(j,j+1);
                ++cnt;
                assert(cnt + 10 < v);
            }
            visit();
        }
        vector <int> ret(n); for (int i=0;i<n;++i) ret[i] = i+1;
        answer(ret);
    }

Compilation message

swaps.cpp: In function 'void solve(int, int)':
swaps.cpp:25:13: warning: unused variable 'a' [-Wunused-variable]
   25 |         int a[300];
      |             ^
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 200 KB Not correct
2 Halted 0 ms 0 KB -