What is the output of `[1,2,3].reverse()`?

JavaScript Professional Easy

JavaScript Professional — Easy

What is the output of `[1,2,3].reverse()`?

Key points

  • The `reverse()` method changes the original array in place.
  • It does not create a new array with reversed elements.
  • The pointer of the array is reversed, not the values themselves.

Ready to go further?

Related questions