上一页 1 2 3 4 5 6 ··· 21 下一页

2018年9月21日

301. Remove Invalid Parentheses

摘要: Remove the minimum number of invalid parentheses in order to make the input string valid. Return all possible results. Note: The input string may cont 阅读全文

posted @ 2018-09-21 21:27 Sheryl Wang 阅读(211) 评论(0) 推荐(0) 编辑

2018年9月16日

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 out in a 阅读全文

posted @ 2018-09-16 13:22 Sheryl Wang 阅读(129) 评论(0) 推荐(0) 编辑

2018年9月9日

刷题关键点总结-动态规划

摘要: 什么情况下使用动态规划? 满足下面三个条件之一: 1.求最大最小值 2.判断是否可行 3.统计方案个数 那么极有可能使用动态规划。 什么情况下不使用动态规划: 1.求出所有具体的方案而非方案个数 dfs等 2.输入数据是一个集合而不是序列 3.暴力算法的复杂度已经是多项式级别的: 4.动态规划擅长与 阅读全文

posted @ 2018-09-09 10:30 Sheryl Wang 阅读(322) 评论(0) 推荐(1) 编辑

2018年9月8日

刷题关键点总结-单调栈、单调队列

摘要: 单调栈,单调队列顾名思义,栈内或者队列内元素具有一致下降或者一致上升的特点。 选用单调栈或者队列的出发点: 使用单调栈或者单调队列一般具有三个出发点: 1.求栈或队列内某个元素左侧或者右侧第一个比它大或者小的元素。 单调递减栈或者队列可以求得第一个比它大的数字。单调递增栈或者队列可以求第一个比它小的 阅读全文

posted @ 2018-09-08 00:17 Sheryl Wang 阅读(206) 评论(0) 推荐(0) 编辑

2018年3月5日

coin change

摘要: You 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 nee 阅读全文

posted @ 2018-03-05 23:49 Sheryl Wang 阅读(123) 评论(0) 推荐(0) 编辑

2017年6月14日

常用vim命令

摘要: (): 分别可以用来跳转到当前行的行首和行尾。 阅读全文

posted @ 2017-06-14 21:40 Sheryl Wang 阅读(85) 评论(0) 推荐(0) 编辑

2017年1月27日

2016年总结

摘要: 这是一个逐梦而梦未圆的一年,也深深的体会到了理想与现实的差距。 leetcode的刷题悬停在面完谷歌北京的这一天,未来洗刷屈辱,继续加油~ 阅读全文

posted @ 2017-01-27 22:59 Sheryl Wang 阅读(75) 评论(0) 推荐(0) 编辑

2016年10月16日

String to Integer (atoi)

摘要: Implement atoi to convert a string to an integer. Hint: Carefully consider all possible input cases. If you want a challenge, please do not see below 阅读全文

posted @ 2016-10-16 22:08 Sheryl Wang 阅读(87) 评论(0) 推荐(0) 编辑

2016年10月6日

Frog Jump

摘要: A frog is crossing a river. The river is divided into x units and at each unit there may or may not exist a stone. The frog can jump on a stone, but i 阅读全文

posted @ 2016-10-06 17:23 Sheryl Wang 阅读(185) 评论(0) 推荐(0) 编辑

2016年10月1日

Median of Two Sorted Arrays

摘要: There are two sorted arrays nums1 and nums2 of size m and n respectively. Find the median of the two sorted arrays. The overall run time complexity sh 阅读全文

posted @ 2016-10-01 16:25 Sheryl Wang 阅读(172) 评论(0) 推荐(0) 编辑

上一页 1 2 3 4 5 6 ··· 21 下一页

导航