- 博客(17)
- 资源 (12)
- 收藏
- 关注
原创 算法:插入排序、归并排序、快速排序、堆排序
说明对排序实现的总结,以下都是基于升序排序[1,2,3…]:插入排序:两层循环嵌套,第一层从第二位开始,index逐步递增;第二层,innerIndex从index-1逐步递减,,在index之前都为有序,如果data[innerIndex] > data[index],则innerIndex++腾出位置(这是插入排序的特点),一直到条件失败,退出内存循环,交换innerIndex...
2019-03-27 19:13:04 1777
原创 算法:Reverse Linked List
说明算法:Minimum Path SumLeetCode地址:https://leetcode.com/problems/reverse-linked-list/题目:Reverse a singly linked list.Example:Input: 1->2->3->4->5->NULLOutput: 5->4->3->2-&g...
2019-03-26 17:32:58 237
原创 算法:Minimum Path Sum(最小路径和)
说明算法:Minimum Path SumLeetCode地址:https://leetcode.com/problems/minimum-path-sum/题目:Given a m x n grid filled with non-negative numbers, find a path from top left to bottom right which minimizes the...
2019-03-26 11:54:49 431
原创 算法:Regular Expression Matching(正则表达式匹配)
说明算法:Regular Expression MatchingLeetCode地址:https://leetcode.com/problems/regular-expression-matching/题目:Given an input string (s) and a pattern §, implement regular expression matching with suppor...
2019-03-22 16:16:52 1256
原创 算法:Valid Sudoku(有效的数独)
说明算法:Valid SudokuLeetCode地址:https://leetcode.com/problems/valid-sudoku/题目:Determine if a 9x9 Sudoku board is valid. Only the filled cells need to be validated according to the following rules:Ea...
2019-03-20 17:11:09 855
原创 算法:Number of Islands(岛屿的个数)
说明算法:Number of IslandsLeetCode地址:https://leetcode.com/problems/number-of-islands/题目:Given a 2d grid map of '1’s (land) and '0’s (water), count the number of islands. An island is surrounded by wat...
2019-03-19 11:36:00 1815
原创 算法:Path Sum(路径总和)
说明算法:Path SumLeetCode地址:https://leetcode.com/problems/path-sum/题目:Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equ...
2019-03-16 22:53:45 1063
原创 算法:Validate Binary Search Tree(验证二叉查找树)
说明算法:Validate Binary Search TreeLeetCode地址:https://leetcode.com/problems/validate-binary-search-tree/题目:Given a binary tree, determine if it is a valid binary search tree (BST).Assume a BST is de...
2019-03-16 22:37:04 422
原创 算法:Maximum Depth of Binary Tree(二叉树的最大深度)
说明算法:Maximum Depth of Binary TreeLeetCode地址:https://leetcode.com/problems/maximum-depth-of-binary-tree/题目:Given a binary tree, find its maximum depth.The maximum depth is the number of nodes alon...
2019-03-16 21:57:52 222
原创 算法:Invert Binary Tree(翻转二叉树)
说明算法:Invert Binary TreeLeetCode地址:https://leetcode.com/problems/invert-binary-tree/题目:Invert a binary tree.Example:Input: 4 / \ 2 7 / \ / \1 3 6 9Output: 4 / ...
2019-03-15 16:42:43 942
原创 算法:String to Integer (atoi)(字符串转换整数)
说明算法:String to Integer (atoi)LeetCode地址:https://leetcode.com/problems/string-to-integer-atoi/题目:Implement atoi which converts a string to an integer.The function first discards as many whitespace...
2019-03-14 10:33:12 1120
原创 算法:Reverse Words in a String(翻转字符串里的单词)
说明算法:Reverse Words in a StringLeetCode地址:https://leetcode.com/problems/reverse-words-in-a-string/题目:Given an input string, reverse the string word by word.Example 1:Input: "the sky is blue"Outp...
2019-03-13 11:07:22 827
原创 算法:Reverse String(反转字符串)
说明算法:Reverse StringLeetCode地址:https://leetcode.com/problems/reverse-string/题目:Write a function that reverses a string. The input string is given as an array of characters char[].Do not allocate e...
2019-03-12 09:44:19 511
原创 算法:Sqrt(x) (x 的平方根)
说明算法:Sqrt(x)LeetCode地址:https://leetcode.com/problems/sqrtx/题目:Implement int sqrt(int x).Compute and return the square root of x, where x is guaranteed to be a non-negative integer.Since the retu...
2019-03-11 10:36:15 1721
原创 算法:Climbing Stairs(爬楼梯) 6种解法
说明算法:Climbing Stairs(爬楼梯)LeetCode地址:https://leetcode.com/problems/climbing-stairs/题目:You are climbing a stair case. It takes n steps to reach to the top.Each time you can either climb 1 or 2 step...
2019-03-10 19:30:14 12649
原创 算法:Sliding Window Maximum(滑动窗口最大值)
说明算法:Sliding Window MaximumLeetCode地址:https://leetcode.com/problems/sliding-window-maximum/题目:Given an array nums, there is a sliding window of size k which is moving from the very left of the arr...
2019-03-09 22:58:38 2007
原创 算法:Design Circular Deque(设计一个双端队列)
说明算法:Design Circular DequeLeetCode地址:https://leetcode.com/problems/design-circular-deque/题目:Design your implementation of the circular double-ended queue (deque).Your implementation should suppor...
2019-03-08 10:21:21 417
注意力 > 时间 > 金钱 用于谋生的知识,学生主要工作是学习,成年人的工作是养家糊口, 这是基本的要求,在这之上,才能有
2023-10-04
注意力 > 时间 > 金钱 用于谋生的知识,学生主要工作是学习,成年人的工作是养家糊口, 这是基本
2023-10-04
Amazon Neptune Workshop-Fundamental-V1.0.pdf
2020-10-31
利用 Auto Scaling 实现 弹性高可用.pdf
2020-10-20
架构师图谱-大作业二.png
2020-09-17
给初中生分享社会需要的人才.pptx
2020-09-16
价值过亿的架构师训练营课面试题和答案.pptx
2020-09-10
ImageAlpha.zip
2020-05-03
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人