Hey Bart,
In order to create our date object, we have to first tell our program that we want to make is in fact a date object. If we were just to write 1421849732000L then our program would most likely interpret that as a string. However we want that to be converted to a date. That's why we use the Date(1421849732000L), to signify to our program that we want a date object with the time of 1421849732000L. and we use the keyword new because, well, we want to create a new date. the creation of new objects always require the new keyword. when creating a object from a class, remember how we use the new keyword there also?
I hope that sort of made sense. Just remember that we always need to use Date() to make a date and input the time of your choice in the parantheses. If you leave it empty, it will make a date object of the current time. and use the new keyword to make a date object
Happy coding and all the best,
Kevin Answer from Kevin Faust on teamtreehouse.com
Times of India
timesofindia.indiatimes.com › news › web-series
Netflix One Piece: 'One Piece' Season 3: Alabasta arc confirmed as new cast, villains, plot and release date are revealed - The Times of India
6 hours ago - News News: The Grand Line is calling once again! Following the massive success of its sophomore outing, Netflix has officially greenlit 'One Piece' Season 3, con.
Videos
08:02
Learn JavaScript DATE objects in 8 minutes! 📅 - YouTube
07:37
JavaScript Date Object Tutorial (2025): Format, Parse & Fix Timezones ...
05:02
How to Get Current Date & Time in JavaScript | Date Object Tutorial ...
10:51
How to Format Dates with Vanilla JavaScript - YouTube
Create a Year Day prototype for Date in JavaScript - YouTube
15:32
Learn the Date Object by Building a Date Formatter | FreeCodeCamp ...
Top answer 1 of 5
1
Hey Bart,
In order to create our date object, we have to first tell our program that we want to make is in fact a date object. If we were just to write 1421849732000L then our program would most likely interpret that as a string. However we want that to be converted to a date. That's why we use the Date(1421849732000L), to signify to our program that we want a date object with the time of 1421849732000L. and we use the keyword new because, well, we want to create a new date. the creation of new objects always require the new keyword. when creating a object from a class, remember how we use the new keyword there also?
I hope that sort of made sense. Just remember that we always need to use Date() to make a date and input the time of your choice in the parantheses. If you leave it empty, it will make a date object of the current time. and use the new keyword to make a date object
Happy coding and all the best,
Kevin
2 of 5
1
Hey Bart,
You seem to have got the important part down. So when creating our Treet object, it takes 3 parameters. when writing strings/ints/etc. these are all primitive data types as you can see here: https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html
we never use the new keyword for these as these things are built into java and we can just use them freely. the program can recognize them with no problem. however something like date is different. notice how we have to import date at the top? now in order to use the date, we have to create that date object using the new keyword. to sum it up cleaner: if you want to create an object whether it be from a class or from an import, you must always use the new keyword.
Does that make sense? please let me know if your still confused
Kevin
W3Schools
w3schools.com › js › js_dates.asp
W3Schools.com
February 4, 2026 - One day (24 hours) is 86 400 000 milliseconds. Now the time is: milliseconds past January 01, 1970 · new Date(milliseconds) creates a new date object as milliseconds plus zero time:
RapidTables
rapidtables.com › tools › todays-date.html
Today's Date | Current date now 📅
3 weeks ago - Date picker of current date.
Yahoo!
yahoo.com › news › videos › spider-man-4-trailer-release-192302730.html
Spider-Man 4 Trailer Release Date Reportedly Set for Brand New Day
The first trailer for Spider-Man: Brand New Day will be released online on March 18, 2026, according to The Beyond Reporter on X, signaling an earlier drop than the expected CinemaCon window. The upda...
Published 14 hours ago
Department of Transportation
azdot.gov › mvd › services › dui-suspension › suspension-revocation
License Revocation and Suspension in Arizona | Department of Transportation
Legislation passed in the 2021 legislative session reinstated the driving privileges of Arizona drivers whose licenses had been suspended or restricted exclusively for failure to pay civil traffic violations. Reinstatement of driver licenses occurred on Sept. 29, 2021, which was the effective ...
GitHub
github.com › segmentio › new-date
GitHub - segmentio/new-date: Create a new Date, accepting more input types than normal, like Unix timestamps.
var newDate = require('new-date'); newDate(new Date); newDate('Wed, 09 Aug 1995 00:00:00 GMT'); newDate('Aug 9, 1995'); newDate('2011-10-10T14:48:00'); newDate(1363288923637); newDate(1363288923); newDate('1363288923637'); newDate('1363288923');
Starred by 14 users
Forked by 4 users
Languages JavaScript 93.8% | Makefile 6.2% | JavaScript 93.8% | Makefile 6.2%
The Globe and Mail
theglobeandmail.com › investing › markets › stocks › NYC-N › pressreleases › 658692 › new-york-city-reit-sets-date-for-q4-results
New York City REIT Sets Date for Q4 Results - The Globe and Mail
4 days ago - Stock Market News Today, March 10 – U.S.