数据结构
H奇点
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
二叉树的建立,遍历和深度检测
include includedefine OVERFLOW -1define OK 1define NULL 0typedef char ElemType; typedef int Status;typedef struct BiTNode { ElemType data; struct BiTNode *lchild, *rchild; }BiTNode, *BiTre原创 2016-12-14 13:42:53 · 324 阅读 · 0 评论 -
leetcode-19 Remove Nth Node From End of List (移除第N个节点)
原题: Given a linked list, remove the n-th node from the end of list and return its head. Example: Given linked list: 1->2->3->4->5, and n = 2. After removing the second node from th...原创 2018-11-26 19:57:22 · 159 阅读 · 0 评论 -
leetcode-141. Linked List Cycle(判定链表是否有环)
问题描述: Given a linked list, determine if it has a cycle in it. 思路: 采用快慢指针法,快指针每次前进两个节点,慢指针每次前进一个节点 无环条件:node.next=NULL 有环条件:快指针指向的节点=慢指针指向的节点 代码: # Definition for singly-linked list. # class ...原创 2018-11-28 12:05:41 · 155 阅读 · 0 评论
分享