标签:
package test; import java.text.SimpleDateFormat; import java.util.Date; import java.util.MissingFormatArgumentException; public class NowTime { public static void main(String[] args) { Date nowDate=new Date(); SimpleDateFormat sdf=new SimpleDateFormat("yyyy年MM月dd日 HH:mm:ss"); String str=sdf.format(nowDate); System.out.println(str); } }
标签:
原文地址:http://www.cnblogs.com/tytr/p/5845294.html