摘要: float类型数保留一位小数float a = 2.5f;float b = 1.2f; System.out.println(a/b);System.out.println((float)(Math.round(a/b*10))/10);保留两位小数 乘100 以此类推两种方法:im... 阅读全文
posted @ 2014-03-14 13:20 海天依色 阅读(15886) 评论(0) 推荐(0)