I'm quite happy with my solution now, except for t...
# advent-of-code
k
I'm quite happy with my solution now, except for the implementation of
leaf
🙂.
h
So compact, great! Although in my taste the named
nodes
map feels a bit redundant because the nodes store the name anyway. A
fun findByName(name:String) = nodes.first{it.name=name}
might work equally well but would allow to use a simple list.