Whether smoking marijuana contributes to weight gain may depend on how much pot a person smokes, in addition to other factors such the person's gender, according to a new study.

Smoking marijuana often gives people the munchies — a sudden increase in appetite that can make them eat a lot at once — so researchers wanted to examine whether this drive to eat might mean that people who smoke pot put on extra pounds over time.

The researchers looked at data from young people who had enrolled at age 12 or 13 in a 13-year study on nicotine dependence in teens. When they reached age 20, the 271 men and 319 women were asked whether they had smoked marijuana in the past year, and if so, how often they smoked. The participants were also asked if they smoked cigarettes. Researchers also tracked the participants' body mass indexes and waist size from ages 17 to 24.

The researchers found that, among the people in the study who smoked marijuana regularly but did not smoke cigarettes, the more often they smoked pot, the more weight they gained. For example, among the men in the study who did not smoke cigarettes, those who smoked marijuana daily gained more weight on average than the men who smoked pot weekly.

"The main finding of our study shows that long-term Cannabis use indeed influences weight gain," study co-author Didier Jutras-Aswad, a professor at the University of Montreal, said in a statement.

"But above all, we noted that certain factors drastically modify this effect," including gender, level of marijuana use and cigarette smoking, Jutras-Aswad said. [11 Odd Facts About Marijuana]

For example, among the men in the study, those who smoked both marijuana and cigarettes gained less weight on average than those who smoked marijuana but not cigarettes.

The reason for this finding may be that the nicotine in cigarettes tends to decrease a person's appetite, said study co-author Emily Dubé, a graduate student at the University of Montreal, told Live Science.

Story continues

However, it turns out that the women in the study who smoked both marijuana and cigarettes did not gain any less weight than the women who smoked only marijuana.

The researchers don't know exactly why there may be this difference in how smoking marijuana and cigarettes may affect men's and women's weight, they said.

However, it may have something to do with how the THC in marijuana and the nicotine in cigarettes affect the body's control over hunger in men versus women, Jutras-Aswad said. "We also know that these targets in the brain are modified by hormonal factors that can fluctuate, in particular, during menstrual cycles," he said.

The study will be published in the August issue of the journal Pharmacology Biochemistry and Behavior.

Follow Agata Blaszczak-Boxe on Twitter. Follow Live Science @livescience, Facebook & Google+. Originally published on Live Science.

Copyright 2015 LiveScience, a Purch company. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.