Marijuana use may pose a greater risk to the developing brains of teenagers than alcohol consumption, according to a new study this week.

The analysis, published Wednesday in the American Journal of Psychiatry, found that cannabis had greater short and long-term consequences than alcohol on four key components of teens' memory. The finding greatly surprised researchers.

"We initially suspected alcohol would have a bigger effect," Patricia Conrod, lead author and professor of psychiatry at the University of Montreal told USA TODAY.

Researchers looked at four cognitive functions: Problem solving, long-term memory, short-term memory manipulation and the ability to stop a habitual behavior when needed. Marijuana had "significant" negative effects on all four, while the study could not tie alcohol to negative effects, Conrod said.

However, alcohol's effects may be greater as teens drink more later in life, Conrod said.

Authors examined nearly 4,000 students in the Montreal region over four years, starting when the average participant was about 13 years old.

The students took yearly memory tests and self-reported their alcohol and marijuana use. Those reports were kept confidential "unless such information indicated imminent risk of harm," authors wrote.

By the fourth year, three-quarters of the students had consumed alcohol at least occasionally, while only about 30 percent of participants had used marijuana. But the study observed more daily marijuana users than alcohol users, Conrod said.

Oct. 5:What is CBD? And why is the cannabis-derived ingredient on the rise for wellness products?

Oct. 4:Cheerleader allegedly brings pot brownies to school for homecoming queen votes, police say

The study found some of marijuana's negative effects were short-term, while others were lasting.

A particularly troubling finding: Young cannabis users may cause long-term damage to a brain function associated with substance abuse.

When studying response inhibition — that's an individual's ability to change their actions to help meet a goal — researchers found that teens using marijuana caused long-term damage to their brains.

Conrod said that finding may help explain a previously "perplexing" phenomenon: Young cannabis users have been shown to be at a greater risk for addiction later in life.