0_0_29471488_5681.cpp:35:8: error: 'sa' was not declared in this scope
vector<sa>a[1000005];
^
0_0_29471488_5681.cpp:35:10: error: template argument 1 is invalid
vector<sa>a[1000005];
^
0_0_29471488_5681.cpp:35:10: error: template argument 2 is invalid
0_0_29471488_5681.cpp:35:21: error: invalid type in declaration before ';' token
vector<sa>a[1000005];
^
0_0_29471488_5681.cpp: In function 'void dfs(int, int)':
0_0_29471488_5681.cpp:39:25: error: request for member 'size' in 'a[x]', which is of non-class type 'int'
for(int i=0; i<a[x].size(); i++)
^
0_0_29471488_5681.cpp:41:21: error: invalid types 'int[int]' for array subscript
int y=a[x][i].to;
^
0_0_29471488_5681.cpp:45:38: error: invalid types 'int[int]' for array subscript
ans+=(f[y]-2)*(f[y]-1)*a[x][i].cost;
^
0_0_29471488_5681.cpp: In function 'int main()':
0_0_29471488_5681.cpp:67:27: error: request for member 'push_back' in 'a[r[i].road::u]', which is of non-class type 'int'
a[r[i].u].push_back({r[i].v,r[i].sp}),a[r[i].v].push_back({r[i].u,r[i].sp});
^
0_0_29471488_5681.cpp:67:65: error: request for member 'push_back' in 'a[r[i].road::v]', which is of non-class type 'int'
a[r[i].u].push_back({r[i].v,r[i].sp}),a[r[i].v].push_back({r[i].u,r[i].sp});
^
0_0_29471488_5681.cpp:80:37: error: request for member 'clear' in 'a[i]', which is of non-class type 'int'
for(int i=1; i<=n; i++)a[i].clear();
^
|