
算法
jyjkitty
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
markdown范本
55. Jump Game题目:Given an array of non-negative integers, you are initially positioned at the first index of the array.Each element in the array represents your maximum jump length at that position.Dete原创 2017-07-05 16:41:17 · 609 阅读 · 0 评论 -
add 2 numbers
2. add 2 numbersYou are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order and each of their nodes contain a single digit. Add the two numbe原创 2017-07-05 22:36:18 · 220 阅读 · 0 评论 -
动态规划 139 Word Break + 322 Coin Change
动态规划总结322. Coin ChangeYou are given coins of different denominations and a total amount of money amount. Write a function to compute the fewest number of coins that you need to make up that amount. If原创 2017-07-15 11:26:55 · 305 阅读 · 0 评论 -
141 linked list cycle
linked list cycleGiven a linked list, determine if it has a cycle in it. Follow up: Can you solve it without using extra space?用tortoise and hare算法,一个快指针一个慢指针。代码块leetcode上的最优解法:# Definition for singl原创 2017-08-10 15:45:25 · 231 阅读 · 0 评论 -
【基础知识】 binary search tree
binary search tree见Binary Search Tree主要特点:小值在左,大值在右最大值:树的最右节点。最小值:树的最左节点。某元素前驱:左子树的最右。某元素的后继:右子树的最左。原创 2017-08-18 10:22:07 · 268 阅读 · 0 评论 -
Python学习 ——enumerate函数
237. Delete Node in a Linked ListWrite a function to delete a node (except the tail) in a singly linked list, given only access to that node.Supposed the linked list is 1 -> 2 -> 3 -> 4 and you are giv原创 2017-08-11 12:52:19 · 273 阅读 · 0 评论 -
# leetcode 110. balanced Binary Tree
leetcode 110. balanced Binary Tree题目Given a binary tree, determine if it is height-balanced.For this problem, a height-balanced binary tree is defined as a binary tree in which the depth of the two sub原创 2017-08-28 10:50:20 · 266 阅读 · 0 评论