Submission #711037

# Submission time Handle Problem Language Result Execution time Memory
711037 2023-03-16T07:32:23 Z Darren0724 Data Transfer (IOI19_transfer) C++17
Compilation error
0 ms 0 KB
#include "transfer.h"
#include <bits/stdc++.h>
#include "grader.cpp"
using namespace std;
std::vector<int> get_attachment(std::vector<int> source) {
	int n=source.size();
    vector<int> a(n*2);
    for(int i=0;i<n;i++){
        a[i]=a[i+n]=source[i];
    }
    return a;
}

std::vector<int> retrieve(std::vector<int> data) {
	int n=data.size()/3;
	vector<int> ans;
    for(int i=0;i<n;i++){
        if(data[i]!=data[i+n]&&data[i]!=data[i+n*2]){
            ans.push_back(data[i]^1);
        }
        else{
            ans.push_back(data[i]);
        }
    }
    return ans;
}

Compilation message

/usr/bin/ld: /tmp/ccLIzAlx.o: in function `main':
grader.cpp:(.text.startup+0x0): multiple definition of `main'; /tmp/ccHcAUJv.o:transfer.cpp:(.text.startup+0x0): first defined here
collect2: error: ld returned 1 exit status