Update Dart code to output same as Java (#522)

This commit is contained in:
liuyuxin
2023-05-30 13:00:16 +08:00
committed by GitHub
parent 5bbcb12979
commit 8247a611d7
14 changed files with 47 additions and 42 deletions

View File

@ -33,7 +33,7 @@ void bucketSort(List<double> nums) {
/* Driver Code*/
void main() {
// 设输入数据为浮点数,范围为 [0, 1)
final nums = [0.78, 0.17, 0.39, 0.26, 0.72, 0.94, 0.21, 0.12, 0.23, 0.68];
final nums = [0.49, 0.96, 0.82, 0.09, 0.57, 0.43, 0.91, 0.75, 0.15, 0.37];
bucketSort(nums);
print('桶排序完成后 = $nums');
print('桶排序完成后 nums = $nums');
}