5.找单链表倒数第k个结点
Node* Get_Kth_Node(Node* plist, int k)
{
Node* p = plist;
Node* q = plist;for (int i = 0; i < k; i++)q = q->next;while (q != NULL)
{p = p->next;q = q->next;
}return p;
}
5.找单链表倒数第k个结点
Node* Get_Kth_Node(Node* plist, int k)
{
Node* p = plist;
Node* q = plist;for (int i = 0; i < k; i++)q = q->next;while (q != NULL)
{p = p->next;q = q->next;
}return p;
}