Implement a function sleep(ms) that pauses execution for the specified number of milliseconds before resolving a Promise.
Example
console.log("Start"); await sleep(1000); console.log("End"); // Logs "End" after ~1 second
JavaScript Function
No test results yet
Click "Run" to execute tests