DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR JAVASCRIPT
javascript array last element
var lastEle = arr.slice(-1)[0]; // or var lastEle = arr.slice(-1).pop();
Source by stackoverflow.com #
PREVIOUS
NEXT
Tagged:
#javascript
#array
#element
ADD COMMENT
Topic
COMMENT
Name
3+7 =
Submit