Submission #938345

# Submission time Handle Problem Language Result Execution time Memory
938345 2024-03-05T04:57:29 Z Sir_Ahmed_Imran Cop and Robber (BOI14_coprobber) C++17
Compilation error
0 ms 0 KB
                              ///~~~LOTA~~~///
#include <bits/stdc++.h>
using namespace std;
#define ll long long
#define append push_back
#define add insert
#define nl "\n"
#define ff first
#define ss second
#define pii pair<int,int>
#define all(x) (x).begin(),(x).end()
#define L0TA ios_base::sync_with_stdio(false);cin.tie(NULL)
#define N 501
int r;
int dept[N];
vector<int> a[N];
void dfs(int v){
    for(auto& i:a[v]){
        if(dept[i])
            r=max(r,dept[v]-dept[i]);
        else{
            dept[i]=dept[v]+1;
            dfs(i);
        }
    }
}
int start(int n,vector<bool> g[N]){
    for(int i=0;i<n;i++)
        for(int j=r=0;j<n;j++)
            if(g[i][j]) a[i].append(j);
    dept[0]=1;
    dfs(0);
    if(r>3) return -1;
    return 0;
}
int nextMove(int v){
    return -1;
}

Compilation message

/usr/bin/ld: /tmp/ccdrOgHI.o: in function `main':
grader.cpp:(.text.startup+0x16c): undefined reference to `start(int, bool (*) [500])'
collect2: error: ld returned 1 exit status