Is there a simpler solution if there were a max of 2? I am curious