in reply to any loop ideas?

Please read through Control statements and looping; that should give you some ideas.

HTH,

planetscape