Goats are much smarter than they might appear at first glance, a study has shown.
The animals quickly learn how to solve complex tasks and have "excellent" long-term memories, say scientists.
Researchers trained a group of goats to retrieve food from a box by pulling on a lever and then lifting it.
On average the goats figured out the multi-step solution within 12 attempts. Ten months later, it took them less than two minutes to remember how they did it.
Dr Alan McElligott, from Queen Mary, University of London, said: "Our results challenge the common misconception that goats aren't intelligent animals - they have the ability to learn complex tasks and remember them for a long time.
"This could explain why they are so successful in colonising new environments."
It was the first time scientists had investigated the ability of goats to learn complicated physical tasks.
Co-author Dr Elodie Briefer, from ETH Zurich, the Swiss Federal Institute of Technology, said: "The speed at which the goats completed the task at 10 months compared to how long it took them to learn indicates excellent long-term memory."
Before each learning session, some of the 12 goats had a chance to watch another goat demonstrate the task.
But those without a demonstrator were just as quick to learn as goats that observed what to do.
"This shows that goats prefer to learn on their own rather than by watching others," said Dr Briefer.
Goats are unusually adaptable to harsh environments and good at finding food sources in the wild, both traits that might be linked to their intelligence, the researchers believe.
The findings are reported in the latest edition of the journal Frontiers in Zoology.