当前位置:网站首页>Kotlin 常用知识点汇总
Kotlin 常用知识点汇总
2022-07-25 23:12:00 【享哥。】
val s="%.2f".format(8.956244) //8.96 数字四舍五入 2位小数
数字去尾法到2位小数
val format = DecimalFormat("0.##")
//未保留小数的舍弃规则,RoundingMode.FLOOR表示直接舍弃。
format.roundingMode = RoundingMode.FLOOR
val s2 = format.format(8.956756) //8.95
边栏推荐
- Simulink学习笔记(三)——Simulink自动代码生成(二)「建议收藏」
- Code shoe set precision barrage
- The VM session was closed before any attempt to power it on
- 动态内存管理
- Network Security Learning (11) scanning and blasting
- 驱动板网线直连电脑共享网络配置
- AI首席架构师12-AICA-工业生产过程优化场景下产业落地解析
- Anaconda installation tutorial environment variables (how to configure environment variables)
- Check code generation
- Learning notes of technical art hundred people plan (2) -- vector
猜你喜欢

Drive board network cable directly connected to computer shared network configuration

Network Security Learning (XII) OSI and TCP

向下扎根,向上生长,探寻华为云AI的“根”力量

MathType installation and solution cannot solve the problem of crtl+v

Take root downward, grow upward, and explore the "root" power of Huawei cloud AI

Take away applet with main version of traffic / repair to add main access function of traffic

互联网协议之 IPFS

通用分页功能

Custom MVC principle

Notification设置的小图标显示的是小方块
随机推荐
2021-09-30
Secure code warrior learning record (II)
Ssh server CBC encryption mode vulnerability (cve-2008-5161)
Anaconda installation tutorial environment variables (how to configure environment variables)
@Autowired annotation required attribute
Solve the problem phpstudy failed to import the database
EasyExcel实用技巧
Custom MVC principle
HJ7 取近似值
Ma Tiji Wanmin hall Chef
Unity 使用宏
The small icon of notification setting shows a small square
校验码生成
Drive board network cable directly connected to computer shared network configuration
Tencent map API request source is not authorized, this request source domain name
The difference between overloading and rewriting
新手哪个券商开户最好 开户最安全
技术美术百人计划学习笔记(1)--基础渲染管线
【论文笔记】A Meta-Reinforcement Learning Algorithm for Causal Discovery
Wamp MySQL empty password