The variable a is assigned the first value of the array, and b is assigned the second value of the array. We can also access the value at any index in an array with destructuring by using commas to reach the desired index:
I can see why this may be confusing but it’s working on the false premise that the numerical values in the array would automatically correlate with an arbitrary alphabetical sequence.
…which would produce exactly the same output.
The point is that you assign variable names to elements of the array and by using commas in this way, you skip array elements, so c (or giraffe) is assigned the value of the 5th element in the array, because the 3rd and 4th values are skipped.