雙向循環鏈表的排序

//排序 void sort(dlist_t head) { dlist_t tmp = head->next,p = NULL,q = NULL; //將鏈表置空 head->next = head; head->prev = head; while(tmp!=head){ //保存原鏈表中tmp的下一個節點 q = t
相關文章
相關標籤/搜索