Heapsort (堆排序)是最经典的排序算法之一,在google或者百度中搜一下可以搜到很多非常详细的解析。同样好的排序算法还有quicksort(快速排序)和merge sort(归并排序),选择对这个算法进行分析主要是因为它用到了一个非常有意思的算法技巧:数据结构 - 堆。而且堆排其实是一个看...
分类:
编程语言 时间:
2014-09-16 23:29:41
阅读次数:
406
inplace_merge原型:
std::inplace_merge
default (1)
template
void inplace_merge (BidirectionalIterator first, BidirectionalIterator middle,
BidirectionalIterato...
分类:
其他好文 时间:
2014-09-16 16:02:20
阅读次数:
170
在将ADT和SDK Tool升级到最新(分别是21.1和16.0.1)之后,我的一个工程(相对比较大)在编译并运行的时候,出现错误,Eclipse控制台输出如下信息: Unable to execute dex: Cannot merge new index 67208 into a non-...
分类:
其他好文 时间:
2014-09-16 15:34:50
阅读次数:
170
This table lists and describes the various font sizes that can be applied. Attribute = FontSizeNameTypeDescriptionPhoneFontSizeSmallDouble18.667PhoneF...
分类:
其他好文 时间:
2014-09-16 12:26:00
阅读次数:
162
gem5模拟器提供了四个不同的CPU模型,两个不同的系统模型以及两个不同的内存系统模型,并且支持多种指令集(ARM、ALPHA、MIPS、Power、SPARC和x86),其中可以再ARM、ALPHA和x86三种架构上运行Linux。gem5的许可证是基于BSD的,这就为工业界和学术界的合作搭建了一个好的桥梁。虽然开发一个Full-system的模拟器是很复杂的,但gem5正在借助开源的强大合作力(如mailing lists,wiki,web-based patch reviews,a publicly ...
分类:
其他好文 时间:
2014-09-16 09:16:30
阅读次数:
364
Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the first two lists.思路:增加一个头指...
分类:
其他好文 时间:
2014-09-15 22:38:49
阅读次数:
217
Insert Interval
Given a set of non-overlapping intervals,
insert a new interval into the intervals (merge if necessary).
You may assume that the intervals were initially sorted according to t...
分类:
其他好文 时间:
2014-09-15 17:51:09
阅读次数:
264
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-09-15 12:41:48
阅读次数:
133
Merge Two Sorted Lists:Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the fi...
分类:
编程语言 时间:
2014-09-15 01:02:17
阅读次数:
269
原题地址:https://oj.leetcode.com/problems/add-two-numbers/题意:You are given two linked lists representing two non-negative numbers. The digits are stored i...
分类:
编程语言 时间:
2014-09-14 23:17:17
阅读次数:
292