Home »
MCQs »
JavaScript MCQs
Which JavaScript statement(s) is correct to create Date object(s) with new Date() constructor?
72. Which JavaScript statement(s) is correct to create Date object(s) with new Date() constructor?
- new Date()
- new Date(year, month, day, hours, minutes, seconds, milliseconds)
- new Date(milliseconds)
- new Date(date string)
- All of the above
Answer: E) All of the above
Explanation:
All of the above statements are correct to create Date objects with new Date() constructor.