I chose to use a tree data structure. I spent yesterday writing my own tree implementation and fighting with the borrow checker in
#rust. Then, before going to bed, I looked online to see how others wrote the tree data structure in rust and I found a post that explained how trees are pain in rust. Of course, I see someone else's solution for AOC day 7 in the comments of the post which used a reverse lookup hash table - a much better solution.