码迷,mamicode.com
首页 >  
搜索关键字:merge two sorted lists    ( 21789个结果
LeetCode - Best Time to Buy and Sell 3
这道题在前两个的基础上做稍微改进就可以。下面是AC代码: 1 /** 2 * Design an algorithm to find the maximum profit. You may complete at most two transactions. 3 * @pa...
分类:其他好文   时间:2014-07-22 23:01:13    阅读次数:251
leetcode__Add Two Numbers && Climbing Stairs
You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a single digit. Add the two numbers and return it as a link...
分类:其他好文   时间:2014-05-01 22:08:19    阅读次数:366
SharePoint中删除列表记录
方法1(快速,以理解,可以封装):SPList spListQuestion = spWeb.Lists["Question List"];for (int i = spListQuestion.Items.Count - 1; i >= 0; i--){ spListQuestion.Ite...
分类:其他好文   时间:2014-05-01 21:01:37    阅读次数:448
Remove Duplicates from Sorted Array
没有想通为什么这个简单的问题竟然不是那么简单,太小看它了,以下是两个别人的很不错的solution:Solution1: 1 public class Solution { 2 public int removeDuplicates(int[] A) { 3 // Start...
分类:其他好文   时间:2014-05-01 20:19:26    阅读次数:384
Add Two Numbers
You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a single ...
分类:其他好文   时间:2014-05-01 20:18:54    阅读次数:425
SharePoint列表数据展现方法
方法1:Guid guid = new Guid ("{8238B046-EC5F-46B6-8E18-028F77EC2620}");SPSite Asite = new SPSite ("http://mosslt/");SPList list = Asite.RootWeb.Lists[gui...
分类:其他好文   时间:2014-05-01 18:38:35    阅读次数:290
problem-whether two headless linked lists cross
whether two nohead-linkedlist have the same end 个人信息:就读于燕大本科软件工程专业 目前大三; 本人博客:google搜索“cqs_2012”即可; 个人爱好:酷爱数据结构和算法,希望将来从事算法工作为人民作出自己的贡献; 博客内容:在无头节点的链表里删除元素; 博客时间:2014-4-15; 编程语言:C+...
分类:其他好文   时间:2014-05-01 18:13:31    阅读次数:352
【CareerCup】Trees and Graphs—Q4.3
题目: Given a sorted (increasing order) array, write an algorithm to create a binary tree with minimal height. 翻译: 给定一个有序数组(递增),写程序构建一棵具有最小高度的二叉树。 思路: 要使二叉树的高度最小,则要尽量使其左右子树的节点数目相当,自然就考虑到将其构造成为二叉排序树,且将有序数组的中间大的数作为根节点,这样得到的二叉树的高度便是最小的。...
分类:其他好文   时间:2014-05-01 17:48:45    阅读次数:321
git rebase和merge 区别和应用场景
对于两个分支而言,rebase和merge没有区别,但是rebase更干净,因为log hisitory是线性的,但commit不一定按日期先后排,而是local commit总在后面,merge之后history变得比较复杂,但是commit按日期排序,stackoverflow上有个图示很好: http://stackoverflow.com/questions/16666089/whats...
分类:其他好文   时间:2014-04-30 22:27:40    阅读次数:401
SQL Mirroring[Hot back up with Double machine]
Background: It's fairly common for businesses to want to provide some high availability for their SQL Server databases, and one option is to have two SQL Server databases on separate machines with a SQL Server database mirrored....
分类:数据库   时间:2014-04-30 22:11:38    阅读次数:520
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!