$ ./guess_the_languageProblem Solving — predict the output
Problem Solving — predict the output · easy · #83

What is logged?

console.log('abc'.at(-1), [1, 2, 3].at(-1));
  1. c 3
  2. a 1
  3. c 2
  4. undefined undefined
at() accepts a negative index counted from the end.
Play Problem Solving ▸