0_0_29136909_30293\Main.java:1: 错误: 非法字符: '#'
#include <bits/stdc++.h>
^
0_0_29136909_30293\Main.java:1: 错误: 需要class, interface或enum
#include <bits/stdc++.h>
^
0_0_29136909_30293\Main.java:4: 错误: 非法字符: '#'
#define SIZE 3
^
0_0_29136909_30293\Main.java:4: 错误: 需要class, interface或enum
#define SIZE 3
^
0_0_29136909_30293\Main.java:10: 错误: 需要class, interface或enum
typedef struct _Matrix {
^
0_0_29136909_30293\Main.java:12: 错误: 需要class, interface或enum
int row, column;
^
0_0_29136909_30293\Main.java:13: 错误: 需要class, interface或enum
_Matrix(int pRow, int pColumn) {
^
0_0_29136909_30293\Main.java:15: 错误: 需要class, interface或enum
column = pColumn;
^
0_0_29136909_30293\Main.java:16: 错误: 需要class, interface或enum
memset(arr, 0, sizeof(arr));
^
0_0_29136909_30293\Main.java:17: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:20: 错误: 需要class, interface或enum
for (int i = 0; i < row; i++) {
^
0_0_29136909_30293\Main.java:20: 错误: 需要class, interface或enum
for (int i = 0; i < row; i++) {
^
0_0_29136909_30293\Main.java:21: 错误: 需要class, interface或enum
for (int j = 0; j < column; j++) {
^
0_0_29136909_30293\Main.java:21: 错误: 需要class, interface或enum
for (int j = 0; j < column; j++) {
^
0_0_29136909_30293\Main.java:23: 错误: 需要class, interface或enum
if (arr[i][j] >= mod)
^
0_0_29136909_30293\Main.java:25: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:28: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:32: 错误: 需要class, interface或enum
for (int i = 0; i < row; i++) {
^
0_0_29136909_30293\Main.java:32: 错误: 需要class, interface或enum
for (int i = 0; i < row; i++) {
^
0_0_29136909_30293\Main.java:32: 错误: 需要class, interface或enum
for (int i = 0; i < row; i++) {
^
0_0_29136909_30293\Main.java:33: 错误: 需要class, interface或enum
for (int j = 0; j < b.column; j++) {
^
0_0_29136909_30293\Main.java:33: 错误: 需要class, interface或enum
for (int j = 0; j < b.column; j++) {
^
0_0_29136909_30293\Main.java:34: 错误: 需要class, interface或enum
for (int k = 0; k < column; k++) {
^
0_0_29136909_30293\Main.java:34: 错误: 需要class, interface或enum
for (int k = 0; k < column; k++) {
^
0_0_29136909_30293\Main.java:36: 错误: 需要class, interface或enum
if (ans.arr[i][j] >= mod)
^
0_0_29136909_30293\Main.java:38: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:42: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:45: 错误: 需要class, interface或enum
return *this;
^
0_0_29136909_30293\Main.java:46: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:49: 错误: 需要class, interface或enum
Matrix matrixFastPow(Matrix matrix, long long int n) {
^
0_0_29136909_30293\Main.java:52: 错误: 需要class, interface或enum
for (int i = 0; i < matrix.row; i++)
^
0_0_29136909_30293\Main.java:52: 错误: 需要class, interface或enum
for (int i = 0; i < matrix.row; i++)
^
0_0_29136909_30293\Main.java:52: 错误: 需要class, interface或enum
for (int i = 0; i < matrix.row; i++)
^
0_0_29136909_30293\Main.java:54: 错误: 需要class, interface或enum
while (n > 0) {
^
0_0_29136909_30293\Main.java:57: 错误: 需要class, interface或enum
matrix = matrix * matrix;
^
0_0_29136909_30293\Main.java:58: 错误: 需要class, interface或enum
n >>= 1;
^
0_0_29136909_30293\Main.java:59: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:61: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:65: 错误: 需要class, interface或enum
a %= mod;
^
0_0_29136909_30293\Main.java:66: 错误: 需要class, interface或enum
while (n > 0) {
^
0_0_29136909_30293\Main.java:69: 错误: 需要class, interface或enum
a = (a * a) % mod;
^
0_0_29136909_30293\Main.java:70: 错误: 需要class, interface或enum
n >>= 1;
^
0_0_29136909_30293\Main.java:71: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:73: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:77: 错误: 需要class, interface或enum
void getFac(int num) {
^
0_0_29136909_30293\Main.java:79: 错误: 需要class, interface或enum
for (int i = 1; i * i <= num; i++) {
^
0_0_29136909_30293\Main.java:79: 错误: 需要class, interface或enum
for (int i = 1; i * i <= num; i++) {
^
0_0_29136909_30293\Main.java:79: 错误: 需要class, interface或enum
for (int i = 1; i * i <= num; i++) {
^
0_0_29136909_30293\Main.java:82: 错误: 需要class, interface或enum
fac.push_back(i);
^
0_0_29136909_30293\Main.java:83: 错误: 需要class, interface或enum
if (i * i != num)
^
0_0_29136909_30293\Main.java:85: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:90: 错误: 需要class, interface或enum
for (int i = 2; i * i <= num; i++) {
^
0_0_29136909_30293\Main.java:90: 错误: 需要class, interface或enum
for (int i = 2; i * i <= num; i++) {
^
0_0_29136909_30293\Main.java:90: 错误: 需要class, interface或enum
for (int i = 2; i * i <= num; i++) {
^
0_0_29136909_30293\Main.java:93: 错误: 需要class, interface或enum
while (num % i == 0)
^
0_0_29136909_30293\Main.java:95: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:99: 错误: 需要class, interface或enum
return ret;
^
0_0_29136909_30293\Main.java:100: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:105: 错误: 需要class, interface或enum
if (len == 2)
^
0_0_29136909_30293\Main.java:107: 错误: 需要class, interface或enum
if (len == 3)
^
0_0_29136909_30293\Main.java:110: 错误: 需要class, interface或enum
Matrix trans(2, 2), base(2, 1);
^
0_0_29136909_30293\Main.java:111: 错误: 需要class, interface或enum
trans.arr[0][0] = color - 2;
^
0_0_29136909_30293\Main.java:112: 错误: 需要class, interface或enum
trans.arr[0][1] = color - 1;
^
0_0_29136909_30293\Main.java:113: 错误: 需要class, interface或enum
trans.arr[1][0] = 1;
^
0_0_29136909_30293\Main.java:114: 错误: 需要class, interface或enum
trans.arr[1][1] = 0;
^
0_0_29136909_30293\Main.java:116: 错误: 需要class, interface或enum
base.arr[0][0] = 1ll * color * (color - 1) % mod * (color - 2) % mod;
^
0_0_29136909_30293\Main.java:117: 错误: 需要class, interface或enum
base.arr[1][0] = 1ll * color * (color - 1) % mod;
^
0_0_29136909_30293\Main.java:119: 错误: 需要class, interface或enum
Matrix ans = matrixFastPow(trans, len - 3) * base;
^
0_0_29136909_30293\Main.java:120: 错误: 需要class, interface或enum
return ans.arr[0][0];
^
0_0_29136909_30293\Main.java:121: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:125: 错误: 需要class, interface或enum
cin.tie(0); cout.tie(0);
^
0_0_29136909_30293\Main.java:125: 错误: 需要class, interface或enum
cin.tie(0); cout.tie(0);
^
0_0_29136909_30293\Main.java:126: 错误: 需要class, interface或enum
int num, color;
^
0_0_29136909_30293\Main.java:127: 错误: 需要class, interface或enum
while (cin >> num >> color) {
^
0_0_29136909_30293\Main.java:129: 错误: 需要class, interface或enum
long long int ans = 0;
^
0_0_29136909_30293\Main.java:130: 错误: 需要class, interface或enum
for (auto i : fac)
^
0_0_29136909_30293\Main.java:133: 错误: 需要class, interface或enum
ans = ans * fastPow(num, mod - 2) % mod;
^
0_0_29136909_30293\Main.java:134: 错误: 需要class, interface或enum
ans = ans * color % mod;
^
0_0_29136909_30293\Main.java:135: 错误: 需要class, interface或enum
cout << ans << '\n';
^
0_0_29136909_30293\Main.java:136: 错误: 需要class, interface或enum
}
^
0_0_29136909_30293\Main.java:138: 错误: 需要class, interface或enum
}
^
81 个错误
|