December 12/Los Angeles/MoneyWatch -- A piece of advice for the millions of U.S. college students busily studying for their final exams -- or anyone else who needs to occasionally use their noggin: Lay off the sugar.

According to research by UCLA biology professor Fernando Gomez-Pinilla, binging on soda, candy and sugary snacks for as little as six weeks may reduce brain function. The study, which was conducted on rats, is the first to show that a diet high in fructose slows the brain, which hampers memory and learning.

"Our findings illustrate that what you eat affects how you think," said Gomez-Pinilla, teaches at UCLA's medical school. "Eating a high-fructose diet over the long term alters your brain's ability to learn and remember information."

Earlier research has shown that fructose harms the body through its role in diabetes, obesity and liver problems, but this is the first time that a study has uncovered how the sweetener can harm the brain.

In the study, two groups of rats were fed standard rat food and trained to navigate a maze for five days before starting a high-fructose diet. Six weeks later, one group of rats passed through the maze much more slowly, with  the researchers speculating that the sugar was causing rodents' brain cells to have trouble signaling each other.

Despite being on the same sugary diet, the other group of rats scurried through the maze just fine. What was the difference? The researchers gave these rodents a supplement of omega-3 fatty acids in the form of flax seed oil and docosahexaenoic acid (DHA).

College students or anyone else who need a sugar boost but do not want to compromise their brain power,  should eat foods rich in omega-3 fatty acids like salmon, walnuts and flaxseeds or take one gram of DHA per day, Gmez-Pinilla recommends.