Minimum Spanning Tree
As a challenge I thought I’d try to implement the Minimum Spanning Tree algorithm, and have a play with it. My code is based off the excellent Coding Train video on the same topic which you can watch here. It’s where I got the code from, and then mixed in some code from the Arrays of Objects video too. The result is a rather pleasing moving sea of dots that will join up when they’re close to each other.
Discussion