Any bash user here? I have finished all other medium games with bash, but failed at case 8&9. I can not process over 15000 links in time. Both my graph store solution got similar efficiency. Any hope for bash?
BTW: I use a different algorithm to get the result:
1, from one node, use BFS to get the farthest node
2. from this node, use BFS again to get the farthest node, the number of cycles is the longest distance in the map
I think it should work in a non-directed acrylic graph, am I correct?