I am facing an issue where I need to do some calculations with a number like for example 5000,00 multiplied it by (1,025^3).
So in
val num = 1.34567 val df = DecimalFormat("#.##") df.roundingMode = RoundingMode.CEILING println(df.format(num))
When you run the program, the output will be: 1.34
Check: https://www.programiz.com/kotlin-programming/examples/round-number-decimal