newkeyword and passing an executor function to the
setTimeout()is a Node function which delays the execution of a callback function using the event-loop.
.then()with a success handler callback containing the logic for what should happen if a promise resolves.
.catch()with a failure handler callback containing the logic for what should happen if a promise rejects.
returnpromises constructed within a