답안 #964404

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
964404 2024-04-16T19:23:20 Z marinaluca Super Dango Maker (JOI22_dango3) C++17
컴파일 오류
0 ms 0 KB
#include <bits/stdc++.h>
#include "dango3.h"
using namespace std;
namespace{
   
void solve (vector <int> ans, int x){
    if (x == 1){
        Answer(ans);
        return;
    }
    int mijl = x / 2;
    vector <int> rez;
    for (int i = ans.size(); -- i;){
        swap (ans[i], ans.back());
        int y = ans.back();
        ans.pop_back();
        if (Query(ans) < mijl)
            ans.push_back(y);
        else
            rez.push_back(y);
    }
    solve (ans, mijl);
    solve(rez, x - mijl);
}
}

void solve (int N, int M){
    int n = N, m = M;
    vector <int> v;
    for (int i = 0; i < n * m; ++ i){
        v.push_back(i + 1);
    }
    solve(v, m);
}
/**
signed main(void){
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    cout.tie(NULL);
    return 0 ^ 0;
}
**/

Compilation message

/usr/bin/ld: /tmp/cccFB4p2.o: in function `main':
grader.cpp:(.text.startup+0x111): undefined reference to `Solve(int, int)'
collect2: error: ld returned 1 exit status