0_0_15698524_7446.cpp:24:13: error: array bound is not an integer constant before ']' token
} edge[Max*2];
^
0_0_15698524_7446.cpp:25:13: error: array bound is not an integer constant before ']' token
bool rem[Max];//记录是否到过
^
0_0_15698524_7446.cpp:26:13: error: array bound is not an integer constant before ']' token
int head[Max];
^
0_0_15698524_7446.cpp:27:11: error: array bound is not an integer constant before ']' token
LL num[Max];
^
0_0_15698524_7446.cpp: In function 'void addedge(int, int, int)':
0_0_15698524_7446.cpp:31:6: error: expected unqualified-id before '[' token
edge[tot].u=u;
^
0_0_15698524_7446.cpp:32:6: error: expected unqualified-id before '[' token
edge[tot].v=v;
^
0_0_15698524_7446.cpp:33:6: error: expected unqualified-id before '[' token
edge[tot].value=value;
^
0_0_15698524_7446.cpp:34:6: error: expected unqualified-id before '[' token
edge[tot].next=head[u];
^
0_0_15698524_7446.cpp:35:2: error: 'head' was not declared in this scope
head[u]=tot++;
^
0_0_15698524_7446.cpp: In function 'void dfs(int)':
0_0_15698524_7446.cpp:41:5: error: 'rem' was not declared in this scope
if(rem[k])
^
0_0_15698524_7446.cpp:43:2: error: 'rem' was not declared in this scope
rem[k]=1;
^
0_0_15698524_7446.cpp:44:2: error: 'num' was not declared in this scope
num[k]=1;
^
0_0_15698524_7446.cpp:45:12: error: 'head' was not declared in this scope
for(int i=head[k];i!=-1;i=edge[i].next)
^
0_0_15698524_7446.cpp:45:32: error: expected primary-expression before '[' token
for(int i=head[k];i!=-1;i=edge[i].next)
^
0_0_15698524_7446.cpp:47:13: error: expected primary-expression before '[' token
int t=edge[i].v;
^
0_0_15698524_7446.cpp:51:33: error: expected primary-expression before '[' token
ans+=min(num[t],n-num[t])*edge[i].value;//在下面会加两次
^
0_0_15698524_7446.cpp: In function 'int main()':
0_0_15698524_7446.cpp:65:10: error: 'head' was not declared in this scope
memset(head,-1,sizeof head);
^
0_0_15698524_7446.cpp:66:10: error: 'rem' was not declared in this scope
memset(rem,0,sizeof rem);//初始化
^
0_0_15698524_7446.cpp:67:14: error: '$n' was not declared in this scope
scanf("%d",$n);
^
|