阅读背景:

如果是整数,则使用Ruby round浮点数to_int

来源:互联网 

In ruby, I want to convert a float to an int if it's a whole number. For exampleIn ruby, I want to convert a float to an int if




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: