摘要: 1. java.text.DecimalFormat; //此方法为四舍五入例如:DecimalFormat df = new DecimalFormat("#.0"); //#.0代表一位小数 #.00代表两位小数 以此类推 df.format(num); 2.Math.round(); /... 阅读全文
posted @ 2015-01-30 15:49 Flylater 阅读(622) 评论(0) 推荐(0) 编辑