文章
7
粉丝
204
获赞
4
访问
67.9k
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Scanner;
public class Main {
public static void main(String[] args) throws ParseException {
Scanner cin = new Scanner(System.in);
while (cin.hasNext()) {
Long n = cin.nextLong();
n *= 1000L;
String startTime = "2009-01-01 00:00:00";
SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
Date date = df.parse(startTime);
date.setTime(date.getTime() + n);
 ...
登录后发布评论
暂无评论,来抢沙发