题解 | 小数化整数
小数化整数
https://www.nowcoder.com/practice/e302a62c1fbd4bbf84793e8c52ce4705
print(int(float(input()))) #input()得到的是一个字符串,需要将字符串转化为浮点数,而不能直接从字符串转为整数。
小数化整数
https://www.nowcoder.com/practice/e302a62c1fbd4bbf84793e8c52ce4705
print(int(float(input()))) #input()得到的是一个字符串,需要将字符串转化为浮点数,而不能直接从字符串转为整数。
相关推荐