java 숫자 자릿수 표현하기 (소수점 자리 원하는 자리수만 나타내기)
String pattern = “#####.##”; DecimalFormat dformat = new DecimalFormat(pattern);
요런 방식으로 하면
1234.5667 => 1234.56 으로 된다.
This article is licensed under CC BY 4.0 by the author.
String pattern = “#####.##”; DecimalFormat dformat = new DecimalFormat(pattern);
요런 방식으로 하면
1234.5667 => 1234.56 으로 된다.