Language: C++

#include<iostream>
#include<algorithm>
#include<vector>
using namespace std;
int kai(int n) {
	if (n == 0) {
		return 1;
	}
	else {
		return n * kai(n - 1);
	}
}
int he(int a, int b) {
	return a * 3 + b;
}
int main() {
	int n = 9;
	vector<vector<int>> hyo(n,vector<int> (n));
	vector<vector<int>> qhyo;
	int uni = -1;
	vector<int> mju0((n - 1) / 2);
	vector<int> mju1((n - 1) / 2);
	int ans = 15;
	for (int i = 1; 2 * i < n; i++) {
		mju0[i - 1] = i; mju1[i - 1] = i + ((n - 1) / 2);
	}
	vector<int> ju0((n - 1) / 2);
	vector<int> ju1((n - 1) / 2);
	ju0 = mju0;
	ju1 = mju1;
	vector<int> jan = {253164479,253189607,252163902,252964761,227495855,253083033,227006135,227403253,227801299,228187986,228482510,227004074,227273433,165328076,164579227};
	int type;
	cout << "type" << "はいくつ";
	cin >> type;
	vector<vector<int>> cy(11,vector<int> (11));
	for (int i = 0; i < 11; i++) {
		cy[i][i] = 0;
		for (int j = (i + 1) % 11; j != i; j = (j + 1) % 11) {
			if ((j - i + 11) % 11 <= 5) {
				cy[i][j] = 1;
			}
			else {
				cy[i][j] = -1;
			}
		}
	}
	while (type != -1) {
		uni = -1;
		if (type == 0) {
			int c, d;
			cout << "c,d"<<"はいくつ";
			cin >> c >> d;//2 3->2,2 6->13,(7 3,7 6)-> 14
			for (int i = 0; i < n; i++) {
				for (int j = 0; j < n; j++) {
					vector<int> v(9);
					int x = (i - j + 9) % 9;
					if (x == 1 or x == 4 or x == c or x == d) {
						hyo[i][j] = -1;
					}
					else if (x == 0) {
						hyo[i][j] = 0;
					}
					else {
						hyo[i][j] = 1;
					}
				}
			}
		}
		if (type == 1) {
			for (int i = 0; i < 3; i++) {
				for (int j = 0; j < 3; j++) {
					vector<int> v(9);//14
					for (int k = 0; k < 3; k++) {
						v[he((i + 1) % 3, k)] = 1;
						v[he((i + 2) % 3, k)] = -1;
					}
					v[he(i, j)] = 0;
					v[he(i, (j+ 1) % 3)] = 1;
					v[he(i, (j + 2) % 3)] = -1;
					hyo[he(i, j)] = v;
				}
			}
		}
		if (type == 2) {
			int c, d;
			cout << "c,d" << "はいくつ";
			cin >> c >> d;
			vector<int> ji(11);
			ji[0] = 0; ji[c] = 0; ji[d] = 0;
			int th = 1;
			for (int i = 1; i < 11; i++) {
				if (i != c and i != d) {
					ji[i] = th;
					th++;
				}
			}
			hyo[0][0] = 0;
			for (int i = 0; i < 11; i++) {
				if (ji[i] != 0) {
					int xx = cy[i][0] + cy[i][c] + cy[i][d];
					if (abs(xx) == 3) {
						uni = 100;
					}
					else {
						hyo[ji[i]][0] = xx;
						hyo[0][ji[i]] = -xx;
					}
					for (int j = 0; j < 11; j++) {
						if (ji[j] != 0) {
							hyo[ji[i]][ji[j]] = cy[i][j];
						}
					}2
				}
			}
		}
		for (int ty = 0; ty < n and uni < 0; ty++) {
			if (ty == 0) {
				qhyo = hyo;
			}
			vector<int> ti1((n - 1) / 2);
			vector<int> ti2((n - 1) / 2);
			int xy = 0;
			int xz = 0;
			for (int i = 0; i < n; i++) {
				if (qhyo[ty][i] == 1) {
					ti1[xy] = i;
					xy++;
				}
				else if (ty != i) {
					ti2[xz] = i;
					xz++;
				}
			}
			vector<int> ti(n, ty);
			for (int i = 1; i < n; i++) {
				if (2 * i < n) {
					ti[i] = ti1[i - 1];
				}
				else {
					ti[i] = ti2[i - ((n + 1) / 2)];
				}
			}
			for (int j = 0; j < n and uni<0; j++) {
				for (int k = 0; k < n; k++) {
					hyo[j][k] = qhyo[ti[j]][ti[k]];
				}
				for (int j = 0; j < kai((n - 1) / 2) and uni<0; j++) {
					for (int k = 0; k < kai((n - 1) / 2) and uni<0; k++) {
						vector<int> jun(n, 0);
						for (int i = 1; i < n; i++) {
							if (2 * i < n) {
								jun[i] = ju0[i - 1];
							}
							else {
								jun[i] = ju1[i - (n + 1) / 2];
							}
						}
						long long qkaz = 0;
						for (int x = 1; x < n; x++) {
							for (int y = x + 1; y < n; y++) {
								qkaz = qkaz * 2 + (((hyo[jun[x]][jun[y]]) + 1) / 2);
							}
						}
						for (int l = 0; l < ans; l++) {
							if (qkaz == jan[l]) {
								uni = l;
							}
						}
						next_permutation(ju1.begin(), ju1.end());
					}
					next_permutation(ju0.begin(), ju0.end());
				}
			}
			ju0 = mju0; ju1 = mju1;
		}
		cout << uni<<endl<<"typeはいくつ？";
		cin >> type;
	}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:112:43: error: expected ';' before '}' token
  112 |                                         }2
      |                                           ^
      |                                           ;
  113 |                                 }
      |                                 ~