![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
LintCode
Yiin
这个作者很懒,什么都没留下…
展开
-
[LintCode] Sort Integers 整数排序
[LintCode] Sort Integers 整数排序 Given an integer array, sort it in ascending order. Use selection sort, bubble sort, insertion sort or any O(n2) algorithm.Example Given [3, 2, 1, 4, 5], return [1, 2, 3原创 2017-05-19 17:07:30 · 389 阅读 · 0 评论 -
[Lintcode]删除链表中元素
删除链表中等于给定值val的所有节点。 样例 给出链表 1->2->3->3->4->5->3, 和 val = 3, 你需要返回删除3之后的链表:1->2->4->5。/** * Definition for singly-linked list. * public class ListNode { * int val; * ListNode next; *原创 2017-05-19 19:02:49 · 195 阅读 · 0 评论 -
[Lintcode]二叉树的最大节点
在二叉树中寻找值最大的节点并返回。 样例 给出如下一棵二叉树: 1 / \ -5 2 / \ / \ 0 3 -4 -5 返回值为 3 的节点。class Solution { public: /** * @param root the root of binary tree * @return the max node原创 2017-05-19 19:48:18 · 1839 阅读 · 0 评论