Moving helper functions to their own file. Finishing find, but hits recursion limit.