问题描述:

In the below code

void tread(gonptr &head){

int coefficient, exponent;

scanf("%d",&n);

I'm having this kind of error when compiling

main.c:59:25: error: expected ';', ',' or ')' before '&' token

void pwrite(PolyPointer &head){

can anyone help?

网友答案:

As per the code visible in the error message, you need to change

void pwrite(PolyPointer &head)

to

void pwrite(PolyPointer *head)

In C, there is no reference thing, it's all about pointers.

As pointed out by Mr. @zenith in the comments,the same is applicable for tread() also.

N.B : Code related to tread() function is irrelevant to this particular error message, anyway.

相关阅读:
Top