The researchers said that in flies just 12 brain cells were responsible for what is known as "associative learning".
They describe their findings in the journal Cell.
Associative memories are made when an animal learns to link a cue to a particular outcome. It might for example learn that a certain odour is a sign that a predator is nearby.
"So the appearance of that odour predicts that something bad is going to happen," explained Gero Miesenbock from the University of Oxford, UK, who led this study.
Previous research had already identified that the brain cells or neurons responsible for this type of learning are those that produce dopamine. This is a chemical which acts as a signal that can be transmitted from cell to cell in the brain.
Professor Miesenbock and his team "tapped into these gene regulatory mechanisms" of the neurons - programming them to respond to a laser.
They modified the neurons by adding a sort of trigger, or receptor, to each one. This receptor was activated by a chemical called ATP.
"Since there's no ATP floating around in the fly's brain, the [modified] receptors remain closed and the flies behave just like normal flies that don't have the receptor," said Professor Miesenbock.
Now for the laser-activated trickery.
The scientists injected ATP into the flies' brains, in a form that was locked inside a light-sensitive chemical cage.
"[Then] we turned on the laser light and the light sensitive cage fell apart," Professor Miesenbock explained. "The ATP was released and acted only on the cells [with] the receptor."
Click Here for the rest of the article.