import java.text.DateFormatSymbols; import java.util.Calendar; public class Main { public static void main(String[] args) { String dayNames[] = new DateFormatSymbols().getWeekdays(); Calendar date2 = Calendar.getInstance(); System.out.println("Today is a " + dayNames[date2.get(Calendar.DAY_OF_WEEK)]); } }