foo.cc: In function 'Listnode* Insert(int*, int)':
foo.cc:12:5: error: expected ',' or ';' before 'int'
int i,m=0;
^~~
foo.cc:13:10: error: 'i' was not declared in this scope
for (i=0;i<n;i++){
^
foo.cc:15:15: error: 'm' was not declared in this scope
b[m]=a[i]
^
foo.cc:21:10: error: 'i' was not declared in this scope
for (i=0;i<m;i++){
^
foo.cc:21:16: error: 'm' was not declared in this scope
for (i=0;i<m;i++){
^
foo.cc:25:16: error: 'insertTail' was not declared in this scope
head = insertTail(head, t);
^~~~~~~~~~
foo.cc:25:16: note: suggested alternative: 'Insert'
head = insertTail(head, t);
^~~~~~~~~~
Insert
foo.cc: In function 'Listnode* insertTail(Listnode*, Listnode*)':
foo.cc:73:2: error: 'node' was not declared in this scope
node *p = h;
^~~~
foo.cc:73:8: error: 'p' was not declared in this scope
node *p = h;
^
[Hydro](https://hydro.ac)提供评测服务