Submission #1311779

#TimeUsernameProblemLanguageResultExecution timeMemory
1311779norrawichzzzJelly Flavours (IOI20_jelly)C++20
Compilation error
0 ms0 KiB
#include <bits/stdc++.h>
using namespace std;

const int MXV = 2005;

int find_maximum_unique(int x, int y, vector<int> &a, vector<int> &b) {
    int n=a.size();

    vector<vector<int>> dp(MXV, vector<int>(MXV));
    dp[0][0] = 0;

    
    for (int e=0; e<n; e++) {
        for (int i=MXV-1; i>=0; i--) {
            for (int j=MXV-1; j>=0; j--) {
                if (i-a[e] >= 0) dp[i][j] = max(dp[i-a[e]][j]+1, dp[i][j]);
                if (j-b[e] >= 0) dp[i][j] = max(dp[i][j-b[e]]+1, dp[i][j]);
            }
        }
    }
    return dp[x][y];
}

int main() {
    return 0;
}

Compilation message (stderr)

/usr/bin/ld: /tmp/ccLKQKuM.o: in function `main':
grader.cpp:(.text.startup+0x0): multiple definition of `main'; /tmp/ccGabXyh.o:jelly.cpp:(.text.startup+0x0): first defined here
/usr/bin/ld: /tmp/ccLKQKuM.o: in function `main':
grader.cpp:(.text.startup+0x1ff): undefined reference to `find_maximum_unique(int, int, std::vector<int, std::allocator<int> >, std::vector<int, std::allocator<int> >)'
collect2: error: ld returned 1 exit status