移动
文章平均质量分 77
jmspan
这个作者很懒,什么都没留下…
展开
-
LeetCode 283. Move Zeroes(移动数字0)
原题网址:https://leetcode.com/problems/move-zeroes/Given an array nums, write a function to move all 0's to the end of it while maintaining the relative order of the non-zero elements.For exam原创 2016-04-14 10:21:19 · 455 阅读 · 0 评论 -
LeetCode 286. Walls and Gates(墙与门)
原题网址:https://leetcode.com/problems/walls-and-gates/You are given a m x n 2D grid initialized with these three possible values.-1 - A wall or an obstacle.0 - A gate.INF - Infinity means an em原创 2016-04-15 01:10:25 · 1217 阅读 · 0 评论 -
LeetCode 351. Android Unlock Patterns(安卓解锁)
原题网址:https://leetcode.com/problems/android-unlock-patterns/Given an Android 3x3 key lock screen and two integers m and n, where 1 ≤ m ≤ n ≤ 9, count the total number of unlock patterns of the An原创 2016-05-25 01:34:55 · 5424 阅读 · 0 评论 -
LeetCode 174. Dungeon Game(游戏)
原题网址:https://leetcode.com/problems/dungeon-game/The demons had captured the princess (P) and imprisoned her in the bottom-right corner of a dungeon. The dungeon consists of M x N rooms laid ou原创 2016-05-25 01:35:03 · 551 阅读 · 0 评论 -
LeetCode 61. Rotate List(旋转链表)
原题网址:https://leetcode.com/problems/rotate-list/Given a list, rotate the list to the right by k places, where k is non-negative.For example:Given 1->2->3->4->5->NULL and k = 2,return 4-原创 2016-05-21 09:13:10 · 954 阅读 · 0 评论 -
LeetCode 335. Self Crossing(贪吃蛇)
原题网址:https://leetcode.com/problems/self-crossing/You are given an array x of n positive numbers. You start at point (0,0) and moves x[0] metres to the north, then x[1] metres to the west, x[原创 2016-04-30 01:55:51 · 828 阅读 · 0 评论 -
LeetCode 295. Find Median from Data Stream(数据流中位数)
原题网址:https://leetcode.com/problems/find-median-from-data-stream/Median is the middle value in an ordered integer list. If the size of the list is even, there is no middle value. So the median is原创 2016-04-16 11:09:22 · 1140 阅读 · 0 评论