Submission #226402

# Submission time Handle Problem Language Result Execution time Memory
226402 2020-04-23T17:56:09 Z AaronNaidu Vision Program (IOI19_vision) C++14
Compilation error
0 ms 0 KB
#include <bits/stdc++.h>
using namespace std;

void add_and(vector<int> v) {   
}

void add_or(vector<int> v) {
}

void construct_network(int h, int w, int k) {
    int totSum = 0;
    for (int i = 0; i < h; i++)
    {
        for (int j = 0; j < w; j++)
        {
            for (int x = i; x < h; x++)
            {
                for (int y = 0; y < w; y++)
                {
                    if (abs(i-x) + abs(j-y) == k)
                    {
                        totSum++;
                        add_and({i*w + j, x*w + y});
                    }
                    
                }
                
            }
            
        }
        
    }
    vector<int> last;
    for (int i = 0; i < totSum; i++)
    {
        last.push_back(i + h * w);
    }
    add_or(last); 
}

Compilation message

/tmp/cch6DHpS.o: In function `add_and(std::vector<int, std::allocator<int> >)':
grader.cpp:(.text+0x490): multiple definition of `add_and(std::vector<int, std::allocator<int> >)'
/tmp/ccsiLIsW.o:vision.cpp:(.text+0x0): first defined here
/tmp/cch6DHpS.o: In function `add_or(std::vector<int, std::allocator<int> >)':
grader.cpp:(.text+0x810): multiple definition of `add_or(std::vector<int, std::allocator<int> >)'
/tmp/ccsiLIsW.o:vision.cpp:(.text+0x10): first defined here
collect2: error: ld returned 1 exit status