QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#544544#67. Two Transportations5un_xiaomivita_mboxCompile Error//C++202.6kb2024-09-02 18:46:022024-09-02 18:46:02

Details

Baijan.code: In function ‘void InitB(int, int, std::vector<int>, std::vector<int>, std::vector<int>)’:
Baijan.code:17:43: warning: extended initializer lists only available with ‘-std=c++11’ or ‘-std=gnu++11’
   17 |  for(int i=0;i<m;i++) e[U[i]+1].push_back({V[i]+1,C[i]});
      |                                           ^
Baijan.code:17:56: warning: extended initializer lists only available with ‘-std=c++11’ or ‘-std=gnu++11’
   17 |  for(int i=0;i<m;i++) e[U[i]+1].push_back({V[i]+1,C[i]});
      |                                                        ^
Baijan.code:18:43: warning: extended initializer lists only available with ‘-std=c++11’ or ‘-std=gnu++11’
   18 |  for(int i=0;i<m;i++) e[V[i]+1].push_back({U[i]+1,C[i]});
      |                                           ^
Baijan.code:18:56: warning: extended initializer lists only available with ‘-std=c++11’ or ‘-std=gnu++11’
   18 |  for(int i=0;i<m;i++) e[V[i]+1].push_back({U[i]+1,C[i]});
      |                                                        ^
Baijan.code: In function ‘void slv(int)’:
Baijan.code:28:11: error: ‘i’ does not name a type
   28 |  for(auto i:e[x]) if(dis[i.fi]>dis[x]+i.se) dis[i.fi]=dis[x]+i.se;
      |           ^
Baijan.code:28:67: error: expected ‘;’ before ‘cnt’
   28 |  for(auto i:e[x]) if(dis[i.fi]>dis[x]+i.se) dis[i.fi]=dis[x]+i.se;
      |                                                                   ^
      |                                                                   ;
   29 |  cnt++;
      |  ~~~                                                               
Baijan.code:30:10: error: expected ‘)’ before ‘;’ token
   30 |  vis[x]=1;
      |          ^
      |          )
Baijan.code:28:5: note: to match this ‘(’
   28 |  for(auto i:e[x]) if(dis[i.fi]>dis[x]+i.se) dis[i.fi]=dis[x]+i.se;
      |     ^