See live example here: https://zbrucyp.github.io/genetic-algorithm/
A set of organisms start in their environment. The ones that land closest to the goal are most likely to be able to "reproduce" and pass their genes into the next generation.
Over time (and based on variable inputs), the organisms can improve at achieving the goal.
A fun project inspired by this video and this video