Language: C++

#include <iostream>
#include <ccomplex>
#include <vector>
#include <cassert>
#include <utility>
#include <algorithm>
#include <string>
#include <deque>
#include <queue>
#include <functional>
#include <cmath>
#include <iomanip>
#include <map>
#include <numeric>
#include <list>
#include <assert.h>
#include <math.h>
#include <valarray>
#include <stdio.h>
#include <algorithm>
#include <set>
#include <complex>
#include <list>
#include <time.h>
#include <stack>
#include <locale>
#include <clocale>
#include <ctype.h>
#include <wchar.h>

using namespace std;
typedef long long int LL;
typedef pair<long long int, long long int> pii;
typedef pair<double, double> pdd;

#define SORT(c) sort((c).begin(),(c).end())
#define BACKSORT(c) sort((c).begin(),(c).end(),std::greater<LL>())
#define FOR(i,a,b) for(LL i=(a);i<(b);++i)
#define REP(i,n)  FOR(i,0,n)


int xcomp(vector<LL>& a, vector<LL>& b) {
	return a[0] < b[0];
}

#define XSORT(c) sort((c).begin(),(c).end(),xcomp)

#define ALL(x) (x).begin(),(x).end()
LL mod = 1000000007;


vector<vector<LL>> v(100001, vector<LL>(0));

LL N = 0;

LL sum = 0;

vector<bool> not(100001, false);

void dfs2(vector<bool> &b, int index, vector<LL> path) {
	REP(i, v[index].size()) {
		if (b[v[index][i]] == false) {
			if (v[index][i] != N) {
				b[v[index][i]] = true;
				vector<LL> path2;
				copy(path.begin(), path.end(), back_inserter(path2));
				path2.push_back(v[index][i]);
				dfs2(b, v[index][i], path2);
			}
			else {
				vector<LL> path2;
				copy(path.begin(), path.end(), back_inserter(path2));
				path2.push_back(v[index][i]);
				REP(i, path2.size()) {
					if (i >= (path2.size()+1) / 2) {
						not[path2[i]] = true;
					}
				}
			}
		}
	}
}

void dfs(vector<bool> &b, int index, int l) {
	sum++;
	REP(i, v[index].size()) {
		if (b[v[index][i]] == false) {
			if (not[v[index][i]]==false) {
				b[v[index][i]] = true;
				dfs(b, v[index][i], l + 1);
			}
		}
	}
}

int main() {
	cin >> N;

	REP(i, N - 1) {
		LL a, b;
		cin >> a >> b;
		v[a].push_back(b);
		v[b].push_back(a);
	}

	vector<bool> bo2(N + 1, false);
	vector<LL> p(1,1);
	bo2[1] = true;
	dfs2(bo2, 1, p);

	vector<bool> bo(N + 1, false);
	bo[1] = true;
	dfs(bo, 1, 0);

	if (N - sum < sum) {
		cout << "Fennec" << endl;
	}
	else {
		cout << "Snuke" << endl;
	}
}


Compiler output:
a.cc:58:14: error: expected unqualified-id before 'not' token
   58 | vector<bool> not(100001, false);
      |              ^~~
a.cc: In function 'void dfs2(std::vector<bool>&, int, std::vector<long long int>)':
a.cc:76:58: error: expected ',' before '[' token
   76 |                                                 not[path2[i]] = true;
      |                                                          ^
      |                                                          ,
a.cc:76:58: error: expected identifier before '[' token
a.cc: In lambda function:
a.cc:76:63: error: expected '{' before '=' token
   76 |                                                 not[path2[i]] = true;
      |                                                               ^
a.cc: In function 'void dfs2(std::vector<bool>&, int, std::vector<long long int>)':
a.cc:76:49: error: no match for 'operator!' (operand type is 'dfs2(std::vector<bool>&, int, std::vector<long long int>)::<lambda()>')
   76 |                                                 not[path2[i]] = true;
      |                                                 ^~~~~~~~~~~~~
a.cc:76:49: note: candidate: 'operator!(bool)' (built-in)
a.cc:76:49: note:   no known conversion for argument 1 from 'dfs2(std::vector<bool>&, int, std::vector<long long int>)::<lambda()>' to 'bool'
a.cc: In function 'void dfs(std::vector<bool>&, int, int)':
a.cc:88:33: warning: capture of variable 'v' with non-automatic storage duration
   88 |                         if (not[v[index][i]]==false) {
      |                                 ^
a.cc:52:20: note: 'std::vector<std::vector<long long int> > v' declared here
   52 | vector<vector<LL>> v(100001, vector<LL>(0));
      |                    ^
a.cc:88:34: error: expected ',' before '[' token
   88 |                         if (not[v[index][i]]==false) {
      |                                  ^
      |                                  ,
a.cc:88:34: error: expected identifier before '[' token
a.cc: In lambda function:
a.cc:88:45: error: expected '{' before '==' token
   88 |                         if (not[v[index][i]]==false) {
      |                                             ^~