I did it the slow way again: create a big map of all permutations of possible wiring 'settings' and the corresponding signals you'd expect to see for each number, then filter this against what you see in the input, return the only remaining common setting.
I did it the slow way again: create a big map of all permutations of possible wiring 'settings' and the corresponding signals you'd expect to see for each number, then filter this against what you see in the input, return the only remaining common setting.
https://github.com/owlz84/advent21/blob/d08p2/src/main/scala/org/stuart/advent21/Signals.scala