码迷,mamicode.com
首页 >  
搜索关键字:house robber    ( 848个结果
Leetcode: Paint House II
There are a row of n houses, each house can be painted with one of the k colors. The cost of painting each house with a certain color is different. Yo...
分类:其他好文   时间:2015-12-23 14:30:27    阅读次数:393
sql里面的分页
SELECT TOP 5 * FROM hos_house WHERE HMID NOT IN( SELECT TOP 5 HMID FROM hos_house WHERE PRICE>2500 ORDER BY PRICE) AND PRICE>2500 ORDER BY PRICE---...
分类:数据库   时间:2015-12-15 01:03:51    阅读次数:174
LeetCode198——house robber(不懂dp)
这题,是不能连续抢两间相邻的店铺。我不知道是不是一个环,姑且算作不是一个环。 如果你已经来到了第n间店铺,那么你有两个选择。 1.抢:sum[n] = sum[n - 2] +n.value 。第n - 1不能抢 2.不抢:你的总收益来到前面一家店的收益总和sum[n] =sum[n - ...
分类:其他好文   时间:2015-12-14 18:28:58    阅读次数:116
256. Paint House
题目:There are a row ofnhouses, each house can be painted with one of the three colors: red, blue or green. The cost of painting each house with a certa...
分类:其他好文   时间:2015-12-03 07:12:06    阅读次数:127
[LeetCode]Paint House II
public class Solution { public int minCostII(int[][] costs) { int n = costs.length; if (n == 0) { return 0; } ...
分类:其他好文   时间:2015-12-01 08:26:19    阅读次数:112
[css]我要用css画幅画(五)
接着之前的[css]我要用css画幅画(四), 这次我给小明和静静增加了对话,用了简单的动画效果。github:https://github.com/bee0060/Css-Paint, 完整代码在pages/sun-house-4.html和相关的css中可以找到demo:http://bee00...
分类:Web程序   时间:2015-11-27 17:31:16    阅读次数:282
[LeetCode]House Robber
挺有意思的动态规划题目,只和i-2和i-3家的状态有关,取其中最大值public class Solution { public int rob(int[] nums) { int length = nums.length; if (length == 0) { ...
分类:其他好文   时间:2015-11-27 06:45:12    阅读次数:173
HDU 5538/ 2015长春区域 L.House Building 水题
题意:求给出图的表面积,不包括底面///1085422276#includeusing namespace std ;typedef long long ll;#define mem(a) memset(a,0,sizeof(a))#define meminf(a) memset(a,127,siz...
分类:其他好文   时间:2015-11-19 14:59:53    阅读次数:192
[css]我要用css画幅画(四)
接着之前的[css]我要用css画幅画(三), 今天,我画了两朵云,并给小明介绍了个朋友:静静。github:https://github.com/bee0060/Css-Paint, 完整代码在pages/sun-house-4.html和相关的css中可以找到demo:http://bee006...
分类:Web程序   时间:2015-11-17 00:16:29    阅读次数:237
LeetCode OJ:House Robber II(房屋窃贼II)
After robbing those houses on that street, the thief has found himself a new place for his thievery so that he will not get too much attention. This t...
分类:其他好文   时间:2015-11-15 10:50:13    阅读次数:360
848条   上一页 1 ... 46 47 48 49 50 ... 85 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!