#include<bits×dc++.h>
using namespace std;
//创建结点
typedef struct node
{
int age;
char name[20];
struct node *next;
}Student;
//创建链表
Student * creatList(int n)
{
Student * head = new Student;
Student * pre = head;
for(int i = 0;i < n;i++)
{
printf(“第%d个”,i + 1);
Student * p = new Student;
cin >> p -> age;
cin >> p -> name;
pre -> next = p;
pre = p;
}
return head;
}
//查找链表
void display(Student * head)
{
Student * p = head;
p = p -> next;
while(p != NULL)
{
cout << p -> name << “,” << p -> age << endl;
p = p -> next;
}
}
//求链表的结点个数
int count(Student * head)
{
int i = 0;