Date Object
Date object work's as a data type in JavaScript object is used to display dates on the web page.In JavaScript we use new Date() to create Date object.
Math.round()
Math.round() function is use to get round values of it's nearest integers.
We can create Date object as following ways in JavaScript.
new Date().
new Date(milliseconds).
new Date(date string).
new Date(year,Month,Day,Hours,Minutes,Seconds. Milliseconds)
new Date()
In the new Date(),we are not passing anything inside date constructor and it will return's today's date.
new Date(milliseconds)
It will create Date object by passing milliseconds.
new Date(date string)
It will create date object in the form of string.
new Date(year,Month,.....)
We are passing total 7 properties inside Date constructor and creating Date object in the standard date format.
Previous Century
We can also create precious century Date object .