Given an indexk, return thekthrow of the Pascal's triangle.For example, givenk= 3,Return[1,3,3,1].Note:Could you optimize your algorithm to use onlyO(...
分类:
其他好文 时间:
2014-12-03 21:10:42
阅读次数:
188
Given an array of integers, every element appearstwiceexcept for one. Find that single one.Note:Your algorithm should have a linear runtime complexity...
分类:
其他好文 时间:
2014-12-03 14:01:20
阅读次数:
181
Given an array of integers, every element appearsthreetimes except for one. Find that single one.Note:Your algorithm should have a linear runtime comp...
分类:
其他好文 时间:
2014-12-03 14:00:31
阅读次数:
185
在/etc/rc.d/init.d这个文件中输入的命令在开机时会执行,所以如果只是简单语句可以直接写进去,如果是个脚本,就可以通过这个文件去调用你自己的脚本,经过尝试,结果开机并没有执行,然后发现了文件中的这句话:# Please note that you must run 'chmod +x /...
分类:
其他好文 时间:
2014-12-02 17:03:52
阅读次数:
150
/**
?*?@brief?Codeforces?Round?#280?(Div.?2)?c
?*?@file?c.cpp
?*?@author?mianma
?*?@created?2014/12/02?14:38
?*?@edited??2014/12/02?14:38
?*?@type?math
?*?@note?
?*??...
分类:
其他好文 时间:
2014-12-02 15:27:48
阅读次数:
204
原创作品,出自 “深蓝的blog” 博客,欢迎转载,转载时请务必注明以下出处,否则追究版权法律责任。
深蓝的blog:
现象:notepad++输入中文时出现“卡顿”现象
相似性描述:
notepad++无法输入中文、Notepad++无法输入中文后无反应、Notepad++输入中文时出现“卡死”现象、Notepad++输入中文时出现“假死”现象等等
软件版本:Note...
分类:
其他好文 时间:
2014-12-02 13:34:53
阅读次数:
191
Recover Binary Search TreeTwo elements of a binary search tree (BST) are swapped by mistake.Recover the tree without changing its structure.Note:A sol...
分类:
其他好文 时间:
2014-12-02 13:27:30
阅读次数:
154
/**
?*?@brief?Codeforces?Round?#280?(Div.?2)?b
?*?@file?b.cpp
?*?@author?mianma
?*?@created?2014/12/02?11:11
?*?@edited??2014/12/02?11:11
?*?@type?math
?*?@note
?*/
#i...
分类:
其他好文 时间:
2014-12-02 12:08:14
阅读次数:
136
【题目】
Given an array of strings, return all groups of strings that are anagrams.
Note: All inputs will be in lower-case.
【解析】
题意:给定一个字符串数组,返回所有是“换位词”的字符串。
所谓“换位词/变位词”就是包含相同字母,但字母顺序可能不同的字符串。比...
分类:
其他好文 时间:
2014-12-02 10:35:23
阅读次数:
129
Two elements of a binary search tree (BST) are swapped by mistake.Recover the tree without changing its structure.Note:A solution using O(n) space is ...
分类:
其他好文 时间:
2014-12-02 07:50:37
阅读次数:
171