Ants are smarter than we think. They can utilize their memory to avoid dangerous traps and predators after a single risky experience. As you already know, social animals like ants navigate their way back home using trails of pheromones. Interestingly, a recent study reveals that they also rely heavily on their visual memory in order to avoid any previously experienced dangers. 

Antoine Wystrach, animal behavior expert, and colleagues of the University of Toulouse, France, undertook the research. 

Ants Can't be Duped: Scientists Discover that Insects Utilize their Memories to Avoid Traps and Predators

Ants Can't be Duped: Scientists Discover that Insects Utilize their Memories to Avoid Traps and Predators

Ants Can't be Duped: Scientists Discover that Insects Utilize their Memories to Avoid Traps and Predators

Their research revealed that ants have the ability to relate negative experiences with visual cues. This allows them to memorize dangerous routes and avoid them accordingly.

The experiment was conducted using Melophorus bagoti ants from Australia and Cataglyphis fortis ants belonging to the Sahara.

A pit trap was placed on the path to their nests. In their first attempt, the ants rushed towards their nest and fell into the trap. However, the next time they approached the area the ants paused to survey the area and then carefully took a detour to their nests.

 

Source