Declaring a variable of this form %.2f
what I want is to have maximum 2 digits after decimal point.
As it is now, it shows only two as expected, I would like to have also the trailing zeros removed.
formatString = "< %.2f Km"
where I use formatString
as
String.format(formatString , value)
Is there a way to do it during this part of the code?