can't sort

Helmut Jarausch jarausch at skynet.be
Sat May 17 06:59:12 EDT 2003


Sorry for this question,
but I am just puzzled.

Why does

print [4,1,3,2].sort()

just print
None
?

As far as I understood the docs 'sort'
should take 'cmp' for comparisons which is
well defined for integers.

Thanks for a hint,

Helmut Jarausch

Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany





More information about the Python-list mailing list