That is interesting how you laid that out. My neophytic programming mind is trying to digest everything presented. First, I did not realize semicolons were a thing in for statements (cnt = 0;)
Second, is that a division symbol you are using with "sizeof (trigPins) / sizeof (trigPins[0]);" ???
Talking with you forum experts reminds me just how little I really know. Just enuf to be dangerous most of the time. ...lol