mirror of
https://github.com/krahets/hello-algo.git
synced 2025-12-19 07:17:54 +08:00
Fix some contents.
This commit is contained in:
@@ -16,7 +16,7 @@ def bucket_sort(nums: list[float]) -> None:
|
||||
i = int(num * k)
|
||||
# 将 num 添加进桶 i
|
||||
buckets[i].append(num)
|
||||
# 2. 对各个桶执行排序5
|
||||
# 2. 对各个桶执行排序
|
||||
for bucket in buckets:
|
||||
# 使用内置排序函数,也可以替换成其他排序算法
|
||||
bucket.sort()
|
||||
|
||||
Reference in New Issue
Block a user