Leetcode 2619. Array Prototype Last
Add an Array.prototype.last() method that returns the last element of any array (arrays may contain any JSON values) and returns -1 when the array is empty.
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
0
Hello Interview Premium
Your account is free and you can post anonymously if you choose.