QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#289494#7858. Basic Equation Solvingucup-team1376#Compile Error//C++202.9kb2023-12-23 17:59:272023-12-23 17:59:28

Details

answer.code:23:1: error: ‘vector’ does not name a type
   23 | vector<int>E[N+1];
      | ^~~~~~
answer.code: In function ‘void dfs(int)’:
answer.code:41:26: error: ‘used’ was not declared in this scope
   41 |         tong[++length]=x,used[x]=1;
      |                          ^~~~
answer.code:42:24: error: ‘E’ was not declared in this scope
   42 |         for (int i=0;i<E[x].size();++i)
      |                        ^
answer.code: In function ‘void add(int, int)’:
answer.code:49:9: error: ‘E’ was not declared in this scope
   49 |         E[x].push_back(y),E[y].push_back(x);
      |         ^
answer.code: In function ‘void calc()’:
answer.code:56:41: error: ‘used’ was not declared in this scope
   56 |         for (int i=1;i<=27;++i) rt[i]=i,used[i]=0,E[i].clear();
      |                                         ^~~~
answer.code:56:51: error: ‘E’ was not declared in this scope
   56 |         for (int i=1;i<=27;++i) rt[i]=i,used[i]=0,E[i].clear();
      |                                                   ^
answer.code:68:39: error: ‘delta’ was not declared in this scope
   68 |                         if (find(X[i][delta[i]]-'A'+1)==find(Y[i][delta[i]]-'A'+1)) return 0;
      |                                       ^~~~~
answer.code:68:92: error: return-statement with a value, in function returning ‘void’ [-fpermissive]
   68 |                         if (find(X[i][delta[i]]-'A'+1)==find(Y[i][delta[i]]-'A'+1)) return 0;
      |                                                                                            ^
answer.code:69:46: error: ‘delta’ was not declared in this scope
   69 |                         add(belong[find(X[i][delta[i]]-'A'+1)],belong[find(Y[i][delta[i]]-'A'+1)]);
      |                                              ^~~~~
answer.code:73:39: error: ‘delta’ was not declared in this scope
   73 |                         if (find(X[i][delta[i]]-'A'+1)==find(Y[i][delta[i]]-'A'+1)) return 0;
      |                                       ^~~~~
answer.code:73:92: error: return-statement with a value, in function returning ‘void’ [-fpermissive]
   73 |                         if (find(X[i][delta[i]]-'A'+1)==find(Y[i][delta[i]]-'A'+1)) return 0;
      |                                                                                            ^
answer.code:74:46: error: ‘delta’ was not declared in this scope
   74 |                         add(belong[find(Y[i][delta[i]]-'A'+1)],belong[find(X[i][delta[i]]-'A'+1)]);
      |                                              ^~~~~
answer.code:78:22: error: ‘used’ was not declared in this scope
   78 |                 if (!used[i])
      |                      ^~~~
answer.code:84:53: error: ‘num’ was not declared in this scope; did you mean ‘enum’?
   84 |                         for (int j=1;j<=length;++j) num[tong[j]]=j,S[j]=0;
      |                                                     ^~~
      |                                                     enum
answer.code:86:48: error: ‘E’ was not declared in this scope
   86 |                                 for (int k=0;k<E[tong[j]].size();++k)
      |                                                ^
answer.code:87:52: error: ‘num’ was not declared in this scope; did you mean ‘enum’?
   87 |                                         S[j]|=(1<<(num[E[tong[j]][k]]-1));
      |                                                    ^~~
      |                                                    enum
answer.code:101:31: error: ‘ans’ was not declared in this scope; did you mean ‘abs’?
  101 |                         Adder(ans,dp[10][(1<<length)-1]);
      |                               ^~~
      |                               abs
answer.code: At global scope:
answer.code:105:6: error: redefinition of ‘void dfs(int)’
  105 | void dfs(int x)
      |      ^~~
answer.code:39:6: note: ‘void dfs(int)’ previously defined here
   39 | void dfs(int x)
      |      ^~~
answer.code: In function ‘void dfs(int)’:
answer.code:115:51: error: ‘delta’ was not declared in this scope
  115 |                 for (int i=0;i<X[x].length();++i) delta[x]=i,dfs(x+1),adder(X[x][i],Y[x][i],1);
      |                                                   ^~~~~
answer.code: In function ‘int main()’:
answer.code:128:25: error: ‘d’ was not declared in this scope
  128 |                         d=Y[i].length()-X[i].length();
      |                         ^
answer.code:133:25: error: ‘d’ was not declared in this scope
  133 |                         d=X[i].length()-Y[i].length();
      |                         ^
answer.code:142:30: error: ‘ans’ was not declared in this scope; did you mean ‘abs’?
  142 |         dfs(1),printf("%d\n",ans);
      |                              ^~~
      |                              abs