diff options
author | Michael Stapelberg <stapelberg@debian.org> | 2014-06-19 09:22:53 +0200 |
---|---|---|
committer | Michael Stapelberg <stapelberg@debian.org> | 2014-06-19 09:22:53 +0200 |
commit | 8a39ee361feb9bf46d728ff1ba4f07ca1d9610b1 (patch) | |
tree | 4449f2036cccf162e8417cc5841a35815b3e7ac5 /src/pkg/sort/sort.go | |
parent | c8bf49ef8a92e2337b69c14b9b88396efe498600 (diff) | |
download | golang-8a39ee361feb9bf46d728ff1ba4f07ca1d9610b1.tar.gz |
Imported Upstream version 1.3upstream/1.3
Diffstat (limited to 'src/pkg/sort/sort.go')
-rw-r--r-- | src/pkg/sort/sort.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/pkg/sort/sort.go b/src/pkg/sort/sort.go index f06eb3827..e980c295c 100644 --- a/src/pkg/sort/sort.go +++ b/src/pkg/sort/sort.go @@ -287,9 +287,9 @@ func StringsAreSorted(a []string) bool { return IsSorted(StringSlice(a)) } // Notes on stable sorting: // The used algorithms are simple and provable correct on all input and use // only logarithmic additional stack space. They perform well if compared -// experimentaly to other stable in-place sorting algorithms. +// experimentally to other stable in-place sorting algorithms. // -// Remarks on other algoritms evaluated: +// Remarks on other algorithms evaluated: // - GCC's 4.6.3 stable_sort with merge_without_buffer from libstdc++: // Not faster. // - GCC's __rotate for block rotations: Not faster. @@ -349,7 +349,7 @@ func Stable(data Interface) { // The algorithm needs O((M+N)*log(M)) calls to data.Swap. // // The paper gives O((M+N)*log(M)) as the number of assignments assuming a -// rotation algorithm wich uses O(M+N+gcd(M+N)) assignments. The argumentation +// rotation algorithm which uses O(M+N+gcd(M+N)) assignments. The argumentation // in the paper carries through for Swap operations, especially as the block // swapping rotate uses only O(M+N) Swaps. func symMerge(data Interface, a, m, b int) { |