boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Programming版 - 问一个严肃的实用问题
相关主题
underlying sort algorithm for SET in STL?
嵌入式系统用什么sorting算法比较好?
我写的quick sort
请教一个初级算法问题 (转载)
算法之极弱问
哪位大侠给说说 何时用 merge sort, 何时用 quick sort, 何时
我也来一个, quick sort 只要一行。
两行quicksort,不难些吧
can somebody help me with average running time of insertion sort?
Re: 有娃有老公,但是却感觉自己什么都没有。 (转载)
相关话题的讨论汇总
话题: sort话题: 有序话题: default话题: merge话题: 实用
进入Programming版参与讨论
1 (共1页)
f*******y
发帖数: 988
1
有一个很长的stl list,前95%都是有序的,现在要变成全部有序的,有没有比default
的sort更加
快的办法?
c*****t
发帖数: 1879
2
Well, sort the last 5% with default sort, then merge sort the whole thing
(merge part only for the two parts).

default

【在 f*******y 的大作中提到】
: 有一个很长的stl list,前95%都是有序的,现在要变成全部有序的,有没有比default
: 的sort更加
: 快的办法?

g*****g
发帖数: 34805
3
Or you can do insertion sort with the last 5%, it should do
just fine.

【在 c*****t 的大作中提到】
: Well, sort the last 5% with default sort, then merge sort the whole thing
: (merge part only for the two parts).
:
: default

f*******y
发帖数: 988
4
如果直接call stl list的sort会怎么样?
一般情况偶不喜欢写直接的算法

【在 g*****g 的大作中提到】
: Or you can do insertion sort with the last 5%, it should do
: just fine.

w***g
发帖数: 5958
5
冒泡排序法,对那种基本有序的还是很有效的。

default

【在 f*******y 的大作中提到】
: 有一个很长的stl list,前95%都是有序的,现在要变成全部有序的,有没有比default
: 的sort更加
: 快的办法?

f*****Q
发帖数: 1912
6
不是quicksort或者introsort么?

【在 w***g 的大作中提到】
: 冒泡排序法,对那种基本有序的还是很有效的。
:
: default

s***n
发帖数: 459
7
驿外断桥边,寂寞开无主...

【在 c*****t 的大作中提到】
: Well, sort the last 5% with default sort, then merge sort the whole thing
: (merge part only for the two parts).
:
: default

1 (共1页)
进入Programming版参与讨论
相关主题
Re: 有娃有老公,但是却感觉自己什么都没有。 (转载)
一道C++面试编程题
有人能解释一下这段C++代码吗
A STL sorting algorithm problem
帮帮看看这段tree insertion
[合集] 如何得到一个指向STL元素的指针?
问一个基本问题
如何 randomize 一个sorted的文件 ?
如何sort and merge n 个sorted linked list
如何让python dictionary sorting 的速度变得很快?
相关话题的讨论汇总
话题: sort话题: 有序话题: default话题: merge话题: 实用