how to get current year month and day in java on API 23 code example
Example 1: java get current year
import java.util.Calendar;
int year = Calendar.getInstance().get(Calendar.YEAR);
Example 2: java get year
import java.time.ZoneId;
import java.util.Date;
new Date().toInstant().atZone(ZoneId.systemDefault()).toLocalDate().getYear();