Fruit flies "think" before they act, according to a recent study.

Researchers from the University of Oxford Center for Neural Circuits and Behavior found that fruit flies don't act instinctively or impulsively. Instead they appear to accumulate information before committing to a choice, showing a mark of intelligence.

"Freedom of action from automatic impulses is considered a hallmark of cognition or intelligence," researcher Gero Miesenböck said in a statement. "What our findings show is that fruit flies have a surprising mental capacity that has previously been unrecognized."

For the study, researchers observed Drosophila fruit flies make a choice between two concentrations of an odor presented to them from opposite ends of a narrow chamber, having been trained to avoid one concentration.

When the odor concentrations were very different and easy to tell apart, the flies made quick decisions and almost always moved to the correct end of the chamber.

When the odor concentrations were very close and difficult to distinguish, the flies took much longer to make a decision, and they made more mistakes.

Researchers found that mathematical models developed to describe the mechanisms of decision making in humans and primates also matched the behavior of the fruit flies.

The neuroscientists discovered that fruit flies with mutations in a gene called FoxP took longer than normal flies to make decisions when odors were difficult to distinguish -- they became indecisive.

The researchers tracked down the activity of the FoxP gene to a small cluster of around 200 neurons out of the 200,000 neurons in the brain of a fruit fly.

"'Before a decision is made, brain circuits collect information like a bucket collects water. Once the accumulated information has risen to a certain level, the decision is triggered," researcher Shamik DasGupta said in a statement. "When FoxP is defective, either the flow of information into the bucket is reduced to a trickle, or the bucket has sprung a leak."