Answers for "funtion that return last emelment of array typescripts"

2

how to get last element of array in typescript

var items: String[] = ["tom", "jeff", "sam"];

alert(items[items.length-1])
Posted by: Guest on November-10-2020

Code answers related to "funtion that return last emelment of array typescripts"

Code answers related to "Javascript"

Browse Popular Code Answers by Language