QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#851746#2351. Lost in TransferZhangYiDeCompile Error//C++239.0kb2025-01-10 23:13:052025-01-10 23:13:06

Details

answer.code:54:1: error: ‘constexpr’ does not name a type
   54 | constexpr int mod = 1e9 + 7, mod2 = 998244353;
      | ^~~~~~~~~
answer.code:54:1: note: C++11 ‘constexpr’ only available with ‘-std=c++11’ or ‘-std=gnu++11’
answer.code:55:1: error: ‘constexpr’ does not name a type
   55 | constexpr double eps = 1e-9;
      | ^~~~~~~~~
answer.code:55:1: note: C++11 ‘constexpr’ only available with ‘-std=c++11’ or ‘-std=gnu++11’
answer.code:57:1: error: ‘constexpr’ does not name a type
   57 | constexpr ull npos = string::npos;
      | ^~~~~~~~~
answer.code:57:1: note: C++11 ‘constexpr’ only available with ‘-std=c++11’ or ‘-std=gnu++11’
answer.code:58:1: error: ‘constexpr’ does not name a type
   58 | constexpr int dx[] = {1, 0, -1, 0, 1, 1, -1, -1}, dy[] = {0, 1, 0, -1, 1, -1, 1, -1};
      | ^~~~~~~~~
answer.code:58:1: note: C++11 ‘constexpr’ only available with ‘-std=c++11’ or ‘-std=gnu++11’
answer.code:58:49: error: expected unqualified-id before ‘,’ token
   58 | constexpr int dx[] = {1, 0, -1, 0, 1, 1, -1, -1}, dy[] = {0, 1, 0, -1, 1, -1, 1, -1};
      |                                                 ^
answer.code:58:56: error: expected constructor, destructor, or type conversion before ‘=’ token
   58 | constexpr int dx[] = {1, 0, -1, 0, 1, 1, -1, -1}, dy[] = {0, 1, 0, -1, 1, -1, 1, -1};
      |                                                        ^
answer.code:59:7: error: expected nested-name-specifier before ‘pii’
   59 | using pii = pair<int, int>;
      |       ^~~
answer.code:60:7: error: expected nested-name-specifier before ‘pll’
   60 | using pll = pair<ll, ll>;
      |       ^~~
answer.code:61:7: error: expected nested-name-specifier before ‘cd’
   61 | using cd = complex<double>;
      |       ^~
answer.code:62:1: error: ‘mt19937’ does not name a type
   62 | mt19937 mt(578597529);
      | ^~~~~~~
answer.code:63:1: error: ‘mt19937_64’ does not name a type
   63 | mt19937_64 mt64(chrono::system_clock::now().time_since_epoch().count());
      | ^~~~~~~~~~
answer.code:71:16: error: ‘pii’ was not declared in this scope
   71 | typedef vector<pii> vpair;
      |                ^~~
answer.code:71:19: error: template argument 1 is invalid
   71 | typedef vector<pii> vpair;
      |                   ^
answer.code:71:19: error: template argument 2 is invalid
answer.code:77:16: error: ‘cd’ was not declared in this scope; did you mean ‘gcd’?
   77 | typedef vector<cd> vcd;
      |                ^~
      |                gcd
answer.code:77:18: error: template argument 1 is invalid
   77 | typedef vector<cd> vcd;
      |                  ^
answer.code:77:18: error: template argument 2 is invalid
answer.code:79:44: error: ‘>>’ should be ‘> >’ within a nested template argument list
   79 | typedef priority_queue<int, vi, greater<int>> pqg;
      |                                            ^~
      |                                            > >
answer.code:81:43: error: ‘>>’ should be ‘> >’ within a nested template argument list
   81 | typedef priority_queue<ll, vll, greater<ll>> pqgll;
      |                                           ^~
      |                                           > >
answer.code:104:8: error: ‘pii’ was not declared in this scope
  104 | vector<pii> factorize(int n) {vector<pii> a; for (int i = 2; i*i <= n; ++i) {if (n % i == 0) {int k = 0; while (n % i == 0) ++k, n/=i; a.emplace_back(i, k);}} if (n > 1) a.emplace_back(n, 1); return a;}
      |        ^~~
answer.code:104:11: error: template argument 1 is invalid
  104 | vector<pii> factorize(int n) {vector<pii> a; for (int i = 2; i*i <= n; ++i) {if (n % i == 0) {int k = 0; while (n % i == 0) ++k, n/=i; a.emplace_back(i, k);}} if (n > 1) a.emplace_back(n, 1); return a;}
      |           ^
answer.code:104:11: error: template argument 2 is invalid
answer.code: In function ‘int factorize(int)’:
answer.code:104:38: error: ‘pii’ was not declared in this scope
  104 | vector<pii> factorize(int n) {vector<pii> a; for (int i = 2; i*i <= n; ++i) {if (n % i == 0) {int k = 0; while (n % i == 0) ++k, n/=i; a.emplace_back(i, k);}} if (n > 1) a.emplace_back(n, 1); return a;}
      |                                      ^~~
answer.code:104:41: error: template argument 1 is invalid
  104 | vector<pii> factorize(int n) {vector<pii> a; for (int i = 2; i*i <= n; ++i) {if (n % i == 0) {int k = 0; while (n % i == 0) ++k, n/=i; a.emplace_back(i, k);}} if (n > 1) a.emplace_back(n, 1); return a;}
      |                                         ^
answer.code:104:41: error: template argument 2 is invalid
answer.code:104:138: error: request for member ‘emplace_back’ in ‘a’, which is of non-class type ‘int’
  104 | vector<pii> factorize(int n) {vector<pii> a; for (int i = 2; i*i <= n; ++i) {if (n % i == 0) {int k = 0; while (n % i == 0) ++k, n/=i; a.emplace_back(i, k);}} if (n > 1) a.emplace_back(n, 1); return a;}
      |                                                                                                                                       ...