Threadser.net
數據
關鍵字
功能建議
Following
Threads
Login
串文
串文鏈結
2025-01-03 00:46
I don't like sort() in Python. It's the worst list method. Yup, it doesn't Sort Alphabetically For example: letters = ['z', 'y', 'X', 'w']; letters.sort(); print(letters); Non-alphabetical sorting output: ['X', 'w', 'y', 'z']
讚
5
回覆
7
轉發
作者
Coding Effect
coding_effect
粉絲
3
串文
9+
讚
回覆
轉發
24小時粉絲增長
發文前
3
發文後24小時
3
變化
0 (0.00%)
互動率
(讚 + 回覆 + 轉發) / 粉絲數
400.00%
回覆 (BETA)
最先回覆的內容
發文後
用戶
內容
一小時內
Timothy
uartimcs
It is the same in Java or other programming language because the sorting method on string[] or char []is based on ASCII code. Upper case letters has a smaller ASCII code value than lower case letters. So you need to define a sorting method