ServiceNow Mastery

0.0(0)
Studied by 0 people
call kaiCall Kai
Locked
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/4

encourage image

There's no tags or description

Looks like no tags are added yet.

Last updated 10:00 AM on 8/26/26
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai
Chat

No analytics yet

Send a link to your students to track their progress

5 Terms

1
New cards

What are the three states of a Promise?

Pending, fulfilled, rejected. Once it settles (fulfilled or rejected) it can't change.

2
New cards

What does .then() do, and what does .catch() do?

.then() runs when the Promise fulfills and receives the resolved value. .catch() runs when it rejects and receives the error. They can be chained.

3
New cards

Why does Promise.all() exist? What does it return?

Runs multiple Promises in parallel and waits for all to fulfill. Returns one Promise resolving to an array of all results. If any one rejects, the whole thing rejects immediately.

4
New cards

What is the difference between synchronous and asynchronous code?

Synchronous runs line by line, each blocking the next. Asynchronous starts a task and moves on, handling the result later via a callback/Promise — so slow operations don't freeze everything.

5
New cards

Why is JavaScript single-threaded but still non-blocking? definition start: One call stack runs one thing at a time, but slow operations are handed off to the environment

their callbacks wait in a queue and the event loop runs them only when the stack is clear.