Sorting algorithms/Bubble sort: Difference between revisions
Content added Content deleted
Line 170: | Line 170: | ||
<pre> |
<pre> |
||
>>> foo = [3, 5, 2, 6, 1] |
>>> foo = [3, 5, 2, 6, 1] |
||
>>> sorted(foo) |
|||
[1, 2, 3, 5, 6] |
|||
>>> foo |
>>> foo |
||
[3, 5, 2, 6, 1] |
[3, 5, 2, 6, 1] |