I\'m struggling with the following code that is called by a function and it \'hangs\'. When the code iterates through the for loop, the first time that it finds a match and trie