I am happy to present a collective sort, an ant simulation.
This program has been a part of my artificial intelligence post-graduate degree.
The principle is to watch ants sorting red and blue squares and see the squares grouped in clusters. The surprise comes when you know that no sorting rule is developed.
This simulation reproduces what really happens in nature, when ants sort eggs and larva out.