Evolution doesn't have a goal though, evolution is more like maintenance and jerry rigging than it is engineering.
"England’s calculations suggested that groups of atoms that are driven by external energy sources can behave differently: They tend to start tapping into those energy sources, aligning and rearranging so as to better absorb the energy and dissipate it as heat...
England sees life, and its extraordinary confluence of form and function, as the ultimate outcome of dissipation-driven adaptation and self-replication."
https://www.quantamagazine.org/first-support-for-a-physics-t...