码迷,mamicode.com
首页 >  
搜索关键字:b. ohana cleans up    ( 7828个结果
centos快捷方式类别
Main Categories By including one of the Main Categories in an application‘s desktop entry file, the application will be ensured that it will show up in a section of the application menu dedicated t...
分类:其他好文   时间:2014-09-11 19:38:52    阅读次数:253
英语笔记(9)
further my study 继续深造at nights 每夜, 夜夜,经常在夜里She was a person accustomed to staying up late at nights.她是一个习惯熬夜的人。Instead, I was there to talk about step...
分类:其他好文   时间:2014-09-11 19:09:32    阅读次数:181
#leetcode#Linked List Cycle
1、题目Given a linked list, determine if it has a cycle in it.Follow up:Can you solve it without using extra space?2、思路设置两个指针,一个每次走一步,另一个每次走两步。走两步的一定会追上走...
分类:其他好文   时间:2014-09-11 19:04:32    阅读次数:223
Leetcode: N-Queens II
Follow up for N-Queens problem.Now, instead outputting board configurations, return the total number of distinct solutions.跟N-Queen的考虑方式完全一样,NP问题,用循环递...
分类:其他好文   时间:2014-09-11 13:46:11    阅读次数:176
POJ 1037 (计数 + DP) 一个美妙的栅栏
这道题总算勉勉强强看懂了,DP和计数都很不好想DP部分:称i根木棒的合法方案集合为S(i),第二根木棒比第一根长的方案称作UP方案,反之叫做DOWN方案C[i][k][DOWN] 是S(i)中以第k短(而不是长度为k)的木棒打头的DOWN方案数。假设S(i)中第一根木棒长为x,那么构成合法的方案数有...
分类:其他好文   时间:2014-09-11 11:00:21    阅读次数:358
每日一句(2014-9-11)
we win half the battle when we make up our minds to make the world as we find itincluding the thorns当我们下定决心面对世界上所有事物,包括荆棘难题,就已经打赢了半场战役we win half the ...
分类:其他好文   时间:2014-09-11 08:46:21    阅读次数:245
022给定一个字符串类型(string)表示的小数,打印出它的二进制表示(keep it up)
给定一个字符串类型(string)表示的小数,打印出它的二进制表示。 这个题注意字符串的合法性。 不过下面的代码没有处理那种无限循环的小数, 当出现无限循环小数时,while(other>0)可能永久为true 代码: #include #include std::string to_binary_string(const std::string& vNumStr) { std:...
分类:其他好文   时间:2014-09-11 01:11:31    阅读次数:316
Leetcode dfs N-Queens II
N-Queens II  Total Accepted: 12668 Total Submissions: 38109My Submissions Follow up for N-Queens problem. Now, instead outputting board configurations, return the total number of distinct...
分类:其他好文   时间:2014-09-10 09:38:20    阅读次数:218
021位操作1(keep it up)
给定两个32位的数,N和M,还有两个指示位的数,i和j。 写程序使得N中第i位到第j位的值与M中的相同(即:M变成N的子串且位于N的第i位和第j位之间) 例子: 输入: N = 10000000000, M = 10101, i = 2, j = 6 输出: N = 10001010100 解法: 首先我们把M左移vI位得到Mv; 然后我们保留N的0到I位:Si=N & ((1 然...
分类:其他好文   时间:2014-09-10 01:38:39    阅读次数:191
Populating Next Right Pointers in Each Node II <leetcode>
Follow up for problem "Populating Next Right Pointers in Each Node".What if the given tree could be any binary tree? Would your previous solution stil...
分类:其他好文   时间:2014-09-09 19:57:29    阅读次数:237
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!