public class TestDate {
public static void main(String[] args) {
DateFormat format = new SimpleDateFormat(
Date date
try {
date
date
} catch (ParseException e) {
e
}
long diff = date
long days = diff / (
System
}
}
From:http://tw.wingwit.com/Article/program/Java/hx/201311/26751.html