i just want to make it known that i think most if not all of the
replies in this thread are of not much technical value. They are either
wrong and or misleading, and the perl module mentioned about sorting or
the Java language aspect on sorting, as they are discussed or
represented, are rather
[/T]
OTOH, current versions of Python (and Perl)
[/F]
just curious, but all this use of ( Perl) mean that the Perl folks have
implemented timsort ?
A remarkable case of independent harmonic convergence:
http://mail.python.org/pipermail/python-dev/2002-July/026946.html
Come to think of
Tim Peters schrieb:
O() notation isn't being used
I was replying to Gabriel's post:
In fact it's the other way - losing a factor of 2 is irrelevant,
O(2N)=O(N). The logN factor is crucial here.
Regards,
Jo
--
http://mail.python.org/mailman/listinfo/python-list
Tim Peters wrote:
[/T]
OTOH, current versions of Python (and Perl)
[/F]
just curious, but all this use of ( Perl) mean that the Perl folks have
implemented timsort ?
A remarkable case of independent harmonic convergence:
yeah, java also have 2 interface, Comparator and Comparable, which
equal to python's compareTo() and __cmp__()
Marc 'BlackJack' Rintsch wrote:
In [EMAIL PROTECTED], Tom Cole wrote:
In Java, classes can implement the Comparable interface. This interface
contains only one method, a
Jim Gibson schrieb:
The problem addressed by what is know in Perl as the 'Schwartzian
Transform' is that the compare operation can be an expensive one,
regardless of the whether the comparison uses multiple keys. Since in
comparison sorts, the compare operation will be executed N(logN)
Joachim Durchholz [EMAIL PROTECTED] wrote:
Jim Gibson schrieb:
The problem addressed by what is know in Perl as the 'Schwartzian
Transform' is that the compare operation can be an expensive one,
regardless of the whether the comparison uses multiple keys. Since in
comparison sorts, the
At Tuesday 29/8/2006 07:50, Joachim Durchholz wrote:
Wikipedia says it's going from 2NlogN to N. If a sort is massively
dominated by the comparison, that could give a speedup of up to 100%
(approximately - dropping the logN factor is almost irrelevant, what
counts is losing that factor of 2).
Gabriel Genellina schrieb:
At Tuesday 29/8/2006 07:50, Joachim Durchholz wrote:
Wikipedia says it's going from 2NlogN to N. If a sort is massively
dominated by the comparison, that could give a speedup of up to 100%
(approximately - dropping the logN factor is almost irrelevant, what
counts
[Joachim Durchholz]
Wikipedia says it's going from 2NlogN to N. If a sort is massively
dominated by the comparison, that could give a speedup of up to 100%
(approximately - dropping the logN factor is almost irrelevant, what
counts is losing that factor of 2).
[Gabriel Genellina]
In fact
Tim Peters schrieb:
[Joachim Durchholz]
Wikipedia says it's going from 2NlogN to N. If a sort is massively
dominated by the comparison, that could give a speedup of up to 100%
(approximately - dropping the logN factor is almost irrelevant, what
counts is losing that factor of 2).
[Gabriel
[Joachim Durchholz]
Wikipedia says it's going from 2NlogN to N. If a sort is massively
dominated by the comparison, that could give a speedup of up to 100%
(approximately - dropping the logN factor is almost irrelevant, what
counts is losing that factor of 2).
[Gabriel Genellina]
In fact
Tim Peters wrote:
OTOH, current versions of Python (and Perl)
just curious, but all this use of ( Perl) mean that the Perl folks have
implemented timsort ?
/F
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
I would be interested in comments about how Common Lisp, Scheme, and
Haskell deal with the decorate-sort-dedecorate technique.
%w(FORTRAN LISP COBOL).sort_by{|s| s.reverse}
==[COBOL, FORTRAN, LISP]
--
Common Lisp did kill Lisp. Period. ... It is to Lisp what
C++
In [EMAIL PROTECTED], Tom Cole wrote:
In Java, classes can implement the Comparable interface. This interface
contains only one method, a compareTo(Object o) method, and it is
defined to return a value 0 if the Object is considered less than the
one being passed as an argument, it returns a
In article [EMAIL PROTECTED], Marc 'BlackJack'
Rintsch [EMAIL PROTECTED] wrote:
In [EMAIL PROTECTED], Tom Cole wrote:
In Java, classes can implement the Comparable interface. This interface
contains only one method, a compareTo(Object o) method, and it is
defined to return a value 0 if
Jim Gibson schreef:
The problem addressed by what is know in Perl as the 'Schwartzian
Transform' is that the compare operation can be an expensive one,
regardless of the whether the comparison uses multiple keys. Since in
comparison sorts, the compare operation will be executed N(logN)
Last year, i've posted a tutorial and commentary about Python and
Perl's sort function. (http://xahlee.org/perl-python/sort_list.html)
In that article, i discussed a technique known among juvenile Perlers
as the Schwartzian Transform, which also manifests in Python as its
“key” optional
Well you cross-posted this enough, including a Java group, and didn't
even ask about us... What a pity.
In Java, classes can implement the Comparable interface. This interface
contains only one method, a compareTo(Object o) method, and it is
defined to return a value 0 if the Object is
19 matches
Mail list logo