You are viewing a single comment's thread. Return to all comments →
my code
import java.time.LocalDate; import java.time.format.DateTimeFormatter; public class Solution { public static String getDay(String day, String month, String year) { LocalDate ld = LocalDate.of(Integer.parseInt(year), Integer.parseInt(month), Integer.parseInt(day)); DateTimeFormatter df = DateTimeFormatter.ofPattern("EEEE"); String output = ld.format(df); return output.toUpperCase(); }
Java Date and Time
You are viewing a single comment's thread. Return to all comments →
my code