javascript find first element of array

JavaScript
arr[0]alert($(ary).first());let array = ["a", "b", "c", "d", "e"];

// Both first1 and first2 have the same value.
let [first1] = array;
let first2 = array[0];
Source

Also in JavaScript: