From 5b6a14d1cbc66b6a60ba695b519c210155a35adc Mon Sep 17 00:00:00 2001 From: Berker Peksag Date: Wed, 1 Jun 2016 13:54:33 -0700 Subject: Fix link in programming FAQ. The example actually uses the sort method of list object. --- Doc/faq/programming.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/faq/programming.rst b/Doc/faq/programming.rst index 8157124..b2ad7a7 100644 --- a/Doc/faq/programming.rst +++ b/Doc/faq/programming.rst @@ -1312,7 +1312,7 @@ I want to do a complicated sort: can you do a Schwartzian Transform in Python? The technique, attributed to Randal Schwartz of the Perl community, sorts the elements of a list by a metric which maps each element to its "sort value". In -Python, use the ``key`` argument for the :func:`sort()` function:: +Python, use the ``key`` argument for the :meth:`list.sort` method:: Isorted = L[:] Isorted.sort(key=lambda s: int(s[10:15])) -- cgit v0.12