Reverse the order of the elements in an array:
The result of fruits will be:
The reverse() method reverses the order of the elements in an array.
![]()
The reverse() method is supported in all major browsers.
| Type | Description |
|---|---|
| Array | The array after it has been reversed |
| JavaScript Version: | 1.1 |
|---|
JavaScript Array Object
Your message has been sent to W3Schools.