Q:

get LocalDate in specified format

LocalDate today = LocalDate.now();
 
String formattedDate = today.format(DateTimeFormatter.ofPattern("dd-MMM-yy"));
 
System.out.println(formattedDate);
2
Format LocalDate in Java to required string
0

New to Communities?

Join the community