集合数据准备

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<script>
// Setup collection
var collection = [];
for (var i = 0; i < 200; i++) {
  collection.push({
    index: i,
    data: 'Index element ' + i
  });
}
</script>

jQuery (fastest)

$.each(collection, function(index, element) {
     console.log( index,"SSSSSSSSSSSSSSSSSSSSSSSSSS");
});

js forEach()

collection.forEach(function(element, index) {
    console.log(index,"SSSSSSSSSSSSSSSSSSSSSSSSSS");
});

js for(var x in collection) (fastest)

for (var index in collection) {
    if (collection.hasOwnProperty(index)) 
        console.log(index,"SSSSSSSSSSSSSSSSSSSSSSSSSS");
}

js for

for (var i=0,len=collection.length; i<len ; i++) {
    console.log(i,"SSSSSSSSSSSSSSSSSSSSSSSSSS");
}