正在加载图片...
else cout<"Ⅶ n enter num:" cin>>now ->num /*输入学号至当前接点*/ cout< n enter score cin>now-> score;/*输入成绩至当前接点*/ now -> next NULL if ( head *判断是否第一节点head=NUL米/ head=now;/*头指针指向第一节点*/ else{now->next=head;/*新节点添加在最后米/ head=now }/米 for end*/ 2021/2242021/2/24 11 else {cout<<"\n enter num:" ; cin>>now -> num ; /* 输入学号至当前接点 */ cout<<"\n enter score"; cin>>now -> score ; /* 输入成绩至当前接点 */ now -> next = NULL ; if ( ! head ) /* 判断是否第一节点head=NULL*/ head = now ; /* 头指针指向第一节点 */ else {now->next=head;/* 新节点添加在最后 */ head=now; } } } /* for end */ }
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有