动力电池翻转试验机:C++ 简单问题

来源:百度文库 编辑:神马品牌网 时间:2024/04/29 19:00:48
struct node
{
int info;
struct node* link;
}*h1,*p,*q,*r,*h2;//q在这里定义了
.
.
.

void print(node *list)
{
int j(0);//j为计数器
q=list;
while(q)//遍历连表
{
q=q->link;
printf("%d",q->info);//这里怎么错了?
j++;
j%4?printf("\t"):printf("\n");
}
}