Answers for "calendar to string"

1

java calendar class format

SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
Date date = new Date();
System.out.println(dateFormat.format(date)); //2013/10/15 16:16:39
Posted by: Guest on September-24-2020
0

Convert a date to yyyy mm dd format

const formatYmd = date => date.toISOString().slice(0, 10);
formatYmd(new Date());
Posted by: Guest on October-21-2020

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language