오늘 날짜 얻어 내기
import java.time.LocalDate;import java.time.format.DateTimeFormatter;public class DateExample { public static void main(String[] args) { LocalDate today = LocalDate.now(); DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyyMMdd"); String formattedDate = today.format(formatter); System.out.println("Today's date in yyyymmdd format: " + formattedDate); }}
2024.11.07