这个程序精确度不高,应该出整数的咋都是小数:
请输入一个数字:50
0.0
119.99999999999997
107879.99999999997
96876239.99999996
86994755759.99995
78121193796359.95
7.0152745034375576e+16
6.299708691967547e+19
5.657131390112352e+22
5.0800976886122e+25
4.561922067242364e+28
4.096600936285955e+31
3.678743078862719e+34
3.3035071882177856e+37
2.966545776276492e+40
2.6639548035891015e+43
2.3922284470772363e+46
2.148218481520554e+49
1.9290978041770103e+52
1.7323276799324738e+55
1.555628327481557e+58
1.396952505750758e+61
1.2544617945358532e+64
1.1265052945406902e+67
1.0116005000357451e+70
9.084161225268044e+72
8.157566664285701e+75
7.325485780367334e+78
6.5782780732032e+81
5.907286384250693e+84
5.304736594779049e+87
4.763647554825201e+90
4.277750199496436e+93
3.8414149155002434e+96
3.4495863163690185e+99
3.0977246706844626e+102
2.7817533046883307e+105
2.49801136988545e+108
2.2432114284038293e+111
2.0144013646952683e+114
1.8089301822849225e+117
1.624417289290495e+120
1.4587249168526826e+123
1.3099333509164192e+126
1.1763186903980276e+129
1.0563328740440775e+132
9.485857445728913e+134
8.518289422935821e+137
7.64941441593892e+140
6.869165627223727e+143
请输入一个数字:
请输入一个数字:50
0.0
119.99999999999997
107879.99999999997
96876239.99999996
86994755759.99995
78121193796359.95
7.0152745034375576e+16
6.299708691967547e+19
5.657131390112352e+22
5.0800976886122e+25
4.561922067242364e+28
4.096600936285955e+31
3.678743078862719e+34
3.3035071882177856e+37
2.966545776276492e+40
2.6639548035891015e+43
2.3922284470772363e+46
2.148218481520554e+49
1.9290978041770103e+52
1.7323276799324738e+55
1.555628327481557e+58
1.396952505750758e+61
1.2544617945358532e+64
1.1265052945406902e+67
1.0116005000357451e+70
9.084161225268044e+72
8.157566664285701e+75
7.325485780367334e+78
6.5782780732032e+81
5.907286384250693e+84
5.304736594779049e+87
4.763647554825201e+90
4.277750199496436e+93
3.8414149155002434e+96
3.4495863163690185e+99
3.0977246706844626e+102
2.7817533046883307e+105
2.49801136988545e+108
2.2432114284038293e+111
2.0144013646952683e+114
1.8089301822849225e+117
1.624417289290495e+120
1.4587249168526826e+123
1.3099333509164192e+126
1.1763186903980276e+129
1.0563328740440775e+132
9.485857445728913e+134
8.518289422935821e+137
7.64941441593892e+140
6.869165627223727e+143
请输入一个数字:
[此贴子已经被作者于2023-2-8 15:10编辑过]