Both low-fat and low-carb diets can help you shed pounds, but the latter may offer more heart health benefits, according to a new study published in the Annals of Internal Medicine and reported by The Associated Press.

For the study, researchers from Temple University’s Center for Obesity Research and Education in Philadelphia conducted a two-year study on 307 obese adults without cholesterol or diabetes problems. They placed half on low-carb diets and the others on a low-calorie, low-fat diet. All participants attended group counseling sessions, changed their eating habits and increased physical activity.

Participants also periodically had their weight, blood, bone density and body composition checked throughout the study.

At the end of the two years, researchers found that all participants lost the same amount of weight (about 15 pounds), but those who followed a low-carb diet saw a 23 percent improvement in their HDL (the “good’ cholesterol) compared with only 12 percent for low-fat dieters.

“For a diet, that’s pretty impressive,” said Gary Foster, director of Temple University’s Center for Obesity Research and Education and lead study author.

This “good” cholesterol boost was equal to the results of taking medicines for HDL levels, Foster added.

Why that is, researchers were unable to explain. But Foster believes that dieters shouldn’t obsess about which weight-loss diet to use, because they both work. Instead, he said, dieters should focus on ways to keep them committed to their goal.

Learn how weight loss lowers other heart disease risk factors here.