-1
我试图打印给定日期的一天。我怎样才能做到这一点?如何打印指定日期的日期?
String date = "2015.05.12";
SimpleDateFormat format = new SimpleDateFormat("yyyy.MM.dd");
Date bornDate = format.parse(date);
System.out.println(bornDate.getDay());//this prints "2" instead of "12"