I currently have two nested foreach loops for find a matching pair. The outer one is a list of regular expressions ordered by priority. The inner one is a list of errors. If a regex matches any items of the inner loop I need to know the first one that it matches.
Ex. Outer list 1. /hi/ 2. /bye/
Inner list 1. bike 2. hello 3. hi
I need to get the 1st item from the outer list, 3rd item from inner list.
Because of the number of times I have to run this is it actually consuming consider program time. Any suggestions for a more efficient path?
Thanks, Amos