摘要:
题意描述 查找两个单链表的交点开始的节点。 测试用例 Example 1: Input: intersectVal = 8, listA = [4,1,8,4,5], listB = [5,0,1,8,4,5], skipA = 2, skipB = 3 Output: Reference of t 阅读全文
posted @ 2020-06-01 23:48
灵图
阅读(120)
评论(0)
推荐(0)
摘要:
题意描述 给定一个二叉搜索树,编写一个函数kthSmallest在其中找到第k个最小的元素。 测试用例 Example 1: Input: root = [3,1,4,null,2], k = 1 3 / \ 1 4 \ 2 Output: 1 Example 2: Input: root = [5 阅读全文
posted @ 2020-06-01 23:30
灵图
阅读(93)
评论(0)
推荐(0)