println(String.format("%.0f", dNum/100).toDouble() * 100) // 500.0
println(String.format("%.2f", dNum)) // 454.15
println(String.format("%.8f", dNum)) // 454.14600000
728x90
'Client > Kotlin with AndroidStudio (안드로이드 앱)' 카테고리의 다른 글
Android Kotlin에서의 static final 변수 (0) | 2022.01.30 |
---|---|
[정보] Log.d, Log.e, Log.w, Log.v, Log.i (0) | 2022.01.30 |
Android Firebase Login 구현 순서. _ 개인 기록 (0) | 2022.01.29 |
[정보] Android LinearLayout orientation의 기본값은? (0) | 2022.01.11 |