Available question text
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.
Related questions
Continue with questions that share topics or the same question type.
- Array Prototype ForEach
Coding
- Find First and Last Position of Element in Sorted Array
Coding · Array · Binary Search
- A Graph question, a string question, a couple of array questions.
Coding
- A question around around array and number and SQL about counting employee salary and showing them in descending order
Coding
Sources · 1 reference
These records explain where the question appears. A company tag or candidate report does not guarantee a future interview question.
Hello Interview · 1 record
No company association
Leetcode 2619. Array Prototype Last
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source