racebeginnerconst slow = new Promise(res => setTimeout(() => res('slow'), 200))
const fast = new Promise(res => setTimeout(() => res('fast'), 50))
Promise.race([slow, fast]).then(v => {
console.log(v) // β 'fast'
})Promise.race() returns a promise that settles as soon as the first promise in the iterable settles.
Promise.race instanceof Function is true.
Challenge: Verify Promise.race is a Function instance.