DEV Community

Kaviya R
Kaviya R

Posted on

Functions in Java Script

new Date():

Its a object in java script that is used create the new object in js.The data object represents a single moment in time.

getHours():

This method is used to get the hour of the day from a Date object.The value returned from the getHours() function is in 24 hours format.

getSecond():

This is used to get the specific second from the date object.It returned the 0 to 59 integer value representing the second of the minute

setInterval():

It is a function that calls the specified function at the fixed interval.It is useful for executing tasks at regular interval of time.

Top comments (0)

Image of PulumiUP 2025

Transform Your Cloud Infrastructure

Join PulumiUP 2025 on May 6 for Expert Insights & Demos.

Register Now

👋 Kindness is contagious

Explore a trove of insights in this engaging article, celebrated within our welcoming DEV Community. Developers from every background are invited to join and enhance our shared wisdom.

A genuine "thank you" can truly uplift someone’s day. Feel free to express your gratitude in the comments below!

On DEV, our collective exchange of knowledge lightens the road ahead and strengthens our community bonds. Found something valuable here? A small thank you to the author can make a big difference.

Okay