1.获取当前月1日
Date date = new Date();
SimpleDateFormat sdf = new SimpleDateFormat("yyyyMM01");
String currentDate =sdf.format(date);
System.out.println("currentDate:"+currentDate); //输出当前月1日
Date 处理
阅读 67
2023-04-19
1.获取当前月1日
Date date = new Date();
SimpleDateFormat sdf = new SimpleDateFormat("yyyyMM01");
String currentDate =sdf.format(date);
System.out.println("currentDate:"+currentDate); //输出当前月1日
相关推荐
精彩评论(0)