Skip to content

predict · objects

A sort, and the array it was called on.

Answer before anything runs. Then the machine runs it, and you can step through what it did.

const scores = [10, 9, 100, 1];
const ranked = scores.sort();
const first = scores[0];
What does `first` hold when the program has finished?
Put the names that point at the same object into the same group
name12
scores
ranked