Submission #1083959

# Submission time Handle Problem Language Result Execution time Memory
1083959 2024-09-04T16:09:17 Z nickolasarapidis Connecting Supertrees (IOI20_supertrees) C++17
Compilation error
0 ms 0 KB
#include "supertrees.h"
#include <bits/stdc++.h>
using namespace std;

int construct(vector<vector<int>> p){
	int N = p.size();

	vector<vector<int>> b(N, vector<int>(N, 0));

	for(int i = 0; i < N; i++){
		for(int j = 0; j < N; j++){
			if(satisfied[i][j]) continue;

			for(int k = 0; k < N; k++){
				if(j == k) continue;
				if(b[j][k] == 1) continue;
				if(p[j][k] == p[i][k]){
					b[i][k] = 1;
				}
			}
		}
	}

	build(b);

	return 1;
}

Compilation message

supertrees.cpp: In function 'int construct(std::vector<std::vector<int> >)':
supertrees.cpp:12:7: error: 'satisfied' was not declared in this scope
   12 |    if(satisfied[i][j]) continue;
      |       ^~~~~~~~~