Create a method that returns the last element of an array.
EasyProblem Statement
Create a method that returns the last element of an array.
Sample Input
[10, 20, 30, 40, 50]
Sample Output
50
Limits
Time: 2s · Memory: 256 MB
Create a method that returns the last element of an array.
[10, 20, 30, 40, 50]
50
Time: 2s · Memory: 256 MB