java 如何格式化文件大小呢?
@Test
public void test_formatDigit() {
DecimalFormat df1 = (DecimalFormat) DecimalFormat.getInstance();
df1.setGroupingSize(3);
System.out.println(df1.format(23456789));
}
运行结果:
23,456,789
java 如何格式化文件大小呢?
@Test
public void test_formatDigit() {
DecimalFormat df1 = (DecimalFormat) DecimalFormat.getInstance();
df1.setGroupingSize(3);
System.out.println(df1.format(23456789));
}
运行结果:
23,456,789