Submission #1240739

#TimeUsernameProblemLanguageResultExecution timeMemory
1240739nikulidDigital Circuit (IOI22_circuit)C++20
Compilation error
0 ms0 KiB
#include "insects.h"
#include <vector>

using namespace std;

int min_cardinality(int N) {
	vector<int> type(N);
	int answer=2001;
	for(int i=0; i<N; i++){
		type[i]=i;
	}
	for(int l=0; l<N-1; l++){
		if(type[l] != l) continue;
		
		move_inside(l);
		for(int r=l+1; r<N; r++){
			move_inside(r);
			if(press_button()==2){
				// they are the same type...
				type[r]=l;
			}
			move_outside(r);
		}
		move_outside(l);
	}

	vector<int> count(N, 0);
	for(int i=0; i<N; i++){
		count[type[i]]++;
	}
	for(int i=0; i<N; i++){
		if(count[i]>0){
			answer=min(answer,count[i]);
		}
	}

	return answer;
}

Compilation message (stderr)

circuit.cpp:1:10: fatal error: insects.h: No such file or directory
    1 | #include "insects.h"
      |          ^~~~~~~~~~~
compilation terminated.