Submission #1316653

#TimeUsernameProblemLanguageResultExecution timeMemory
1316653ezzzay3개의 봉우리 (IOI25_triples)C++17
Compilation error
0 ms0 KiB
//#include "triples.h"
#include <bits/stdc++.h>
using namespace std;
#define ll long long
long long count_triples(vector<int> H) {
    int n=H.size();
    ll cnt=0;
    for(int i=0;i<n;i++){
        for(int j=i+1;j<min(n,i+11);j++){
            for(int k=j+1;k<min(n,i+11);k++){
                multiset<int>st={H[i],H[j],H[k]};
                if(st.find(j-i)!=st.end())st.erase(st.find(j-i));
                if(st.find(k-i)!=st.end())st.erase(st.find(k-i));
                if(st.find(k-j)!=st.end())st.erase(st.find(k-j));
                if(st.empty()){
                    cnt++;
                }
            }
            
        }
    }
    return cnt;
}

Compilation message (stderr)

/usr/bin/ld: /tmp/cc6syr7z.o: in function `main':
grader.cpp:(.text.startup+0x16a): undefined reference to `construct_range(int, int)'
collect2: error: ld returned 1 exit status