void nizihanshu(struct node *head,struct node *q) //逆置函数 输入头指针,和尾指针
{
struct node *p;
p=head->next;
head->next=p->next;
p->next=NULL;
q->next=p;
p=head->next;
while(p!=q)
{
head->next=p->next;
p->next=q->next;
q->next=p;
p=head->next;
};
}