Given word = "cat", what does word[9] return?
Explanation
Bracket indexing beyond the available code-unit positions returns undefined. An empty string is the result associated with out-of-range charAt, so transferring that behavior to brackets selects the closest but incorrect alternative.