2012年9月27日

Double转为String,挺有用点的!(Java)

摘要: JAVA中Double类型转换为String类型转载JAVA 中Double类型转换为String类型在JAVA中,当一个Double类型的数据整数部分超过6位时,就会用科学计数法表示,如(123456789.50)表示为(1.234567895E8)若想把Double类型转换为String,则可以用下边的方法public static void main(String[] args) {double s=123456789.50;DecimalFormat format = new DecimalFormat("#.00");String sMoney = format. 阅读全文

posted @ 2012-09-27 23:48 l流沙 阅读(24081) 评论(1) 推荐(0)

导航