import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class Main {
	public static void main(String[] args) {
		String english = "Your Last Login was 2013/10/04 13:06:45 ( 0 Days, 0 Hours, 0 Minutes )";
		String chinese = "您上次登录是 2013/10/04 13:06:45（ 0 天， 0 小时 0 分钟 ）";

		// Assuming the date-time string is in the format, yyyy/MM/dd HH:mm:ss
		DateTimeFormatter dtf = DateTimeFormatter.ofPattern("uuuu/M/d H:m:s");

		// Processing english
		LocalDateTime dt = LocalDateTime.parse(getDateTime(english), dtf);
		System.out.printf("Year: %d, Month: %d, Day: %d, Hour: %d, Minute: %d, Second: %d%n", dt.getYear(),
				dt.getMonthValue(), dt.getDayOfMonth(), dt.getHour(), dt.getMinute(), dt.getSecond());

		// Processing chinese
		dt = LocalDateTime.parse(getDateTime(chinese), dtf);
		System.out.printf("Year: %d, Month: %d, Day: %d, Hour: %d, Minute: %d, Second: %d%n", dt.getYear(),
				dt.getMonthValue(), dt.getDayOfMonth(), dt.getHour(), dt.getMinute(), dt.getSecond());
	}

	static String getDateTime(String s) {
		Matcher matcher = Pattern.compile("\\d{1,4}\\/\\d{1,2}\\/\\d{1,2} \\d{1,2}:\\d{1,2}:\\d{1,2}").matcher(s);
		String strDateTime = "";
		if (matcher.find()) {
			strDateTime = matcher.group();
		}
		return strDateTime;
	}
}