码迷,mamicode.com
首页 >  
搜索关键字:problems    ( 6275个结果
[leetcode]Populating Next Right Pointers in Each Node @ Python
原题地址:https://oj.leetcode.com/problems/populating-next-right-pointers-in-each-node/题意: 1 / \ 2 3 / \ / \ 4 5 6 7变为: ...
分类:编程语言   时间:2014-05-26 23:43:29    阅读次数:332
[leetcode]Copy List with Random Pointer @ Python
原题地址:https://oj.leetcode.com/problems/copy-list-with-random-pointer/题意:A linked list is given such that each node contains an additional random pointe...
分类:编程语言   时间:2014-05-26 23:16:12    阅读次数:368
flash流媒体资料
http://www.docin.com/p-111227070.htmlJava mina和c++ ace做socket长连接 测试报告:http://www.iteye.com/problems/44682c++ RTMP server 做流媒体的流媒体研究博客:http://www.cnblo...
分类:其他好文   时间:2014-05-26 15:37:06    阅读次数:249
[leetcode]Recover Binary Search Tree @ Python
原题地址:https://oj.leetcode.com/problems/recover-binary-search-tree/题意:Two elements of a binary search tree (BST) are swapped by mistake.Recover the tree...
分类:编程语言   时间:2014-05-26 13:25:43    阅读次数:261
[leetcode]Validate Binary Search Tree @ Python
原题地址:https://oj.leetcode.com/problems/validate-binary-search-tree/题意:检测一颗二叉树是否是二叉查找树。解题思路:看到二叉树我们首先想到需要进行递归来解决问题。这道题递归的比较巧妙。让我们来看下面一棵树: ...
分类:编程语言   时间:2014-05-26 10:48:19    阅读次数:291
[leetcode]Same Tree @ Python
原题地址:https://oj.leetcode.com/problems/same-tree/题意:判断两棵树是否是同一棵树。解题思路:这题比较简单。用递归来做。首先判断两个根节点的值是否相同,如果相同,递归判断根的左右子树。代码:# Definition for a binary tree n....
分类:编程语言   时间:2014-05-26 10:30:17    阅读次数:289
[leetcode]Symmetric Tree @ Python
原题地址:https://oj.leetcode.com/problems/symmetric-tree/题意:判断二叉树是否为对称的。Given a binary tree, check whether it is a mirror of itself (ie, symmetric around ...
分类:编程语言   时间:2014-05-26 10:18:52    阅读次数:293
[leetcode]N-Queens @ Python
原题地址:https://oj.leetcode.com/problems/n-queens/题意:经典的N皇后问题。解题思路:这类型问题统称为递归回溯问题,也可以叫做对决策树的深度优先搜索(dfs)。N皇后问题有个技巧的关键在于棋盘的表示方法,这里使用一个数组就可以表达了。比如board=[1, ...
分类:编程语言   时间:2014-05-26 10:07:52    阅读次数:274
[leetcode]N-Queens II @ Python
原题地址:https://oj.leetcode.com/problems/n-queens-ii/题意:和N-Queens这道题其实是一样的,只不过这次要求返回的时N皇后的解的个数的问题。解题思路:上道题使用了递归回溯的解法,这道题我们可以使用非递归回溯来解决,因为如果使用递归回溯来解决,那么代码...
分类:编程语言   时间:2014-05-26 08:14:55    阅读次数:288
uva 101 History Grading
Background Many problems in Computer Science involve maximizing some measure according to constraints. Consider a history exam in which students are asked to put several historical events into chr...
分类:其他好文   时间:2014-05-23 00:14:42    阅读次数:386
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!