function arrayForEach(array, func) { var i; for (i = 0, len = array.length; i < len; i++) { func(array[i]); } }