Submission #212636

# Submission time Handle Problem Language Result Execution time Memory
212636 2020-03-23T22:22:26 Z mohamedsobhi777 Gondola (IOI14_gondola) C++14
Compilation error
0 ms 0 KB
#include <bits/stdc++.h>
#include "gondola.h"
using namespace std ; 

const int N = 3e5 + 7 ; 

int valid(int n, int inputSeq[]){

    vector<int> vis(N , 0) ; 
    int cur = inputSeq[0] -1  ; 
    for(int i = 0 ; i < n; i++){
        if(vis[inputSeq[i]]++)return 0 ; 
        if(--inputSeq[i]!=cur)
            return 0 ; 
        cur = (cur+1) %n ; 
    }
    return 1 ; 
}

Compilation message

/tmp/ccMybOes.o: In function `main':
grader.cpp:(.text.startup+0xc3): undefined reference to `countReplacement'
grader.cpp:(.text.startup+0x106): undefined reference to `replacement'
collect2: error: ld returned 1 exit status