码迷,mamicode.com
首页 >  
搜索关键字:part solution    ( 14980个结果
Edit Distance @Leetcode -- Python
http://oj.leetcode.com/problems/edit-distance/class Solution: # @return an integer def minDistance(self, word1, word2): len1 = len(word1)...
分类:编程语言   时间:2014-05-09 04:19:03    阅读次数:407
Longest Valid Parentheses @Leetcode -- Python
http://oj.leetcode.com/problems/longest-valid-parentheses/ 1 class Solution: 2 # @param s, a string 3 # @return an integer 4 def longestVa...
分类:编程语言   时间:2014-05-09 00:11:38    阅读次数:410
使用内部(com.android.internal)和隐藏(@hide)API[第2部分,定制android.jar]
本文翻译自https://devmaze.wordpress.com/2011/01/18/using-com-android-internal-part-2-hacking-around/在前一篇文章中,我解释了为什么不通过反射机制,不太容易使用com.android.internal包的内部AP...
分类:移动开发   时间:2014-05-08 23:41:40    阅读次数:584
使用内部(com.android.internal)和隐藏(@hide)API[第1部分,介绍]
本文翻译自http://devmaze.wordpress.com/2011/01/18/using-com-android-internal-part-1-introduction/#more-79Android有两类API在SDK中不能使用。第一类就是位于包com.android.interna...
分类:移动开发   时间:2014-05-08 23:05:26    阅读次数:486
使用内部(com.android.internal)和隐藏(@hide)API[第3部分,定制android平台]
本文翻译自https://devmaze.wordpress.com/2011/01/18/using-com-android-internal-part-3-custom-android-platform/在前一篇文章中我展示了如何创建定制的original-android.jar,包含内部API...
分类:移动开发   时间:2014-05-08 22:53:47    阅读次数:481
SAP smartforms之Zebra print control language
因为在做个小标签的时候需要将部分字符旋转180度,在scn上找了很久也发布了自己的提问,不过最终的结果却不尽人意。Rotated text in smartforms need use the PCL to control the printer,But part of our printers w...
分类:其他好文   时间:2014-05-08 22:32:20    阅读次数:471
LeetCode --- Two Sum
题目链接附上代码: 1 #include 2 #include 3 #include 4 using namespace std; 5 6 class Solution { 7 public: 8 vector twoSum(vector &numbers, int target) ...
分类:其他好文   时间:2014-05-08 17:50:11    阅读次数:253
leetcode第一刷_Binary Tree Level Order Traversal II
很简单的题目,在想是不是后面就不要更这么简答的了,大家都会写,没人看啊。层序遍历的基础上,加了保存每一层,加了从下往上输出,就是一个vector和一个stack的问题嘛,无他,但手熟尔。 class Solution { public: vector > levelOrderBottom(TreeNode *root) { vector > res; if...
分类:其他好文   时间:2014-05-08 11:17:46    阅读次数:268
leetcode第一刷_Convert Sorted List to Binary Search Tree
好,二叉搜索树粉末登场,有关他的问题有这么几个,给你一个n,怎样求所有的n个节点的二叉搜索树个数?能不能把所有的这些二叉搜索树打印出来? 这道题倒不用考虑这么多,直接转就行了,我用的思想是分治,每次找到一半的位置,分离出中间节点,作为新子树的根节点,然后递归构造前半部分和后半部分。 class Solution { public: TreeNode *sortedListToBST(L...
分类:其他好文   时间:2014-05-08 11:07:14    阅读次数:266
LeetCode Container With Most Water
class Solution{ public: int maxArea(vector& height) { int len = height.size(), low = 0, high = len -1 ; int maxArea = 0; ...
分类:其他好文   时间:2014-05-08 10:23:54    阅读次数:287
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!