- Hands-On Data Science and Python Machine Learning
- Frank Kane
- 60字
- 2021-07-15 17:15:01
The sort function
Finally, let's have a built-in sort function that you can use:
z = [3, 2, 1]
z.sort()
z
So if I start with list z, which is 3,2, and 1, I can call sort on that list, and z will now be sorted in order. The output of the above code is as follows:
[1, 2, 3]
推薦閱讀
- Visual FoxPro 程序設(shè)計(jì)
- 我的第一本算法書
- 薛定宇教授大講堂(卷Ⅳ):MATLAB最優(yōu)化計(jì)算
- Koa開發(fā):入門、進(jìn)階與實(shí)戰(zhàn)
- Java程序設(shè)計(jì)與實(shí)踐教程(第2版)
- Python自然語言處理(微課版)
- HTML5從入門到精通(第4版)
- NGINX Cookbook
- C# Multithreaded and Parallel Programming
- 編程可以很簡(jiǎn)單
- 從0到1:HTML5 Canvas動(dòng)畫開發(fā)
- Clojure Polymorphism
- Learning Kotlin by building Android Applications
- Java設(shè)計(jì)模式深入研究
- Java EE程序設(shè)計(jì)與開發(fā)實(shí)踐教程