def round_number(f,d): rounded_num = round(f,d) return f"{rounded_num:.{d}f}" if d>0 else str(int(rounded_num)) f,d=input().split() d=int(d) f=float(f) result=round_number(f, d) print(result)
记得把0补齐
使用您的 Hydro 通用账户