Different ways to create an iterator for values

2

Is there any difference between creating an iterator for the values of an array using these two forms?

let myIterator = arr[Symbol.iterator]()
let myIterator2 = arr.values()

I did some testing and at least the result looks the same. I wonder if 'in the gut' there is any difference like performance or other relevant characteristics.

    
asked by anonymous 22.06.2018 / 20:15

0 answers