Kotlin Currency Format

[Solved] Kotlin Currency Format | Kotlin - Code Explorer | yomemimo.com
Question : kotlin currency format

Answered by : nuno-silva

val numberFormat = NumberFormat.getCurrencyInstance()
numberFormat.setMaximumFractionDigits(0);
val convert = numberFormat.format(1000000)
println(convert)
// result: $1,000,000

Source : | Last Update : Tue, 27 Jul 21

Answers related to kotlin currency format

Code Explorer Popular Question For Kotlin