i've gotten around this by naming my images with sequential numbers. then you can just have a constant you change that holds the number of the largest image and you can use that to construct your loop ...
Here's what beginning and experienced developers need to know about working with JavaScript's array, for loop, forEach, map, reduce, substring, and switch. Research suggests there are seven JavaScript ...