Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

how to format numbers in java

double value = 4.2352989244d;
String.format("%.2f", value) //output "4.24");
String.format("%.3f", value)//output("4.235");
 
PREVIOUS NEXT
Tagged: #format #numbers #java
ADD COMMENT
Topic
Name
8+9 =