Today Is A Day Jun 26, 2019 That’s right, today is a day where life begins and ends. People come into this world and they die right out of this world. There’s nothing worth living for. If we’re all just going to end up dead eventually, why bother with any of it? Is that not the case?
For some reason my installation of Java wouldn't let me use SimpleDateFormat to format my dates. So I had to google a different way to do this and found the following works as well. The Date class has a bunch of issues with it to begin with, so this is much cleaner and better as well.
LocalDateTime ldt = LocalDateTime.now();
DateTimeFormatter df = DateTimeFormatter.ofPattern("MM/dd/yyyy", Locale.ENGLISH);
String formattedString = df.format(ldt);
Comments
Post a Comment