上一页 1 ··· 7 8 9 10 11 12 13 14 15 ··· 32 下一页
摘要: 1.题目描述Given two sorted integer arrays A and B, merge B into A as one sorted array.Note:You may assume that A has enough space to hold additional elements from B. The number of elements initialized in A and B are m and n respectively.2.解法分析这道题是归并排序的变种,我们知道,归并那一步应该是要有一个O(N+M)的辅助数组的,由于题目中说可以假设A有足够的空间来容 阅读全文
posted @ 2013-08-25 13:02 曾见绝美的阳光 阅读(253) 评论(0) 推荐(0) 编辑
摘要: 1.题目描述 Given an unsorted integer array, find the first missing positive integer. For example, Given ... 阅读全文
posted @ 2013-08-25 00:26 曾见绝美的阳光 阅读(236) 评论(0) 推荐(0) 编辑
摘要: 1.题目描述 Divide two integers without using multiplication, division and mod operator. 2.解法分析 不用乘除求模运算,一个很容易让人想到的就是用... 阅读全文
posted @ 2013-08-24 23:09 曾见绝美的阳光 阅读(504) 评论(0) 推荐(0) 编辑
摘要: 1.题目描述 Implement strStr(). Returns a pointer to the first occurrence of needle in haystack, or null if needle is ... 阅读全文
posted @ 2013-08-24 00:09 曾见绝美的阳光 阅读(245) 评论(0) 推荐(0) 编辑
摘要: 1.题目描述 Given an array and a value, remove all instances of that value in place and return the new length. The ord... 阅读全文
posted @ 2013-08-23 00:14 曾见绝美的阳光 阅读(203) 评论(0) 推荐(0) 编辑
上一页 1 ··· 7 8 9 10 11 12 13 14 15 ··· 32 下一页