摘要: 1.获取当前是当年的第几天 java.util.Calendar c = Calendar.getInstance(); int day = c.get(Calendar.DAY_OF_YEAR); 阅读全文
posted @ 2018-11-21 10:55 sunseeker 阅读(109) 评论(0) 推荐(0) 编辑
摘要: 1.小数格式化后转字符串百分数(带%)输出 NumberFormat nt = NumberFormat.getPercentInstance(); //设置百分数精确度2即保留两位小数 nt.setMinimumFractionDigits(1); //值 String str= nt.forma 阅读全文
posted @ 2018-11-21 10:54 sunseeker 阅读(722) 评论(0) 推荐(0) 编辑