Beyond the physical benefits, regular exercise does wonders for your mental health, too. And according to a decades-long study, those benefits may extend to brain health, memory and cognitive function.

Research published in the journal Neurology finds that women who were highly fit at middle age were 90 percent less likely to develop dementia in old age, compared to those who were moderately fit or not very fit at all.

First, let’s break down the terms of the study. Back in 1968, researchers from the American Academy of Neurology had 191 Swedish women, with an average age of 50, take a bicycle exercise test until exhaustion, so as to measure their “peak cardiovascular capacity.” 40 of the women, who reached their peak at 120 watts or higher, qualified at a “high fitness” level; 92 clocked in at “medium fitness”; and 59, at “low fitness,” reaching their peak at 80 watts or less, and some having to stop due to high blood pressure or chest pain.

Then, this same group of women was tested for dementia six times over the next 44 years. Of the 44 women who developed dementia during that period, five percent were from the highly fit group; 25 percent, moderately fit,; and 32 percent, low fit.

The researchers noted the limitations of the study, such as the small number of women who participated, the fact that their physical fitness was only tested once in over four decades, and that they were all Swedish.

Still, as study author Helena Horder of the University of Gothenburg in Sweden said in the release, "these findings are exciting because it's possible that improving people's cardiovascular fitness in middle age could delay or even prevent them from developing dementia.”

In other words, no matter what age you are, it may not be too late to make a change to your physical health, and reap the mental benefits, too.

Further research is needed on the brain-fitness connection. As Forbes contributor David DiSalvo suggested, a "comparable study that also tracks cardiovascular disease along with dementia risk," could be enlightening, providing "more evidence that what's good for the heart in terms of fitness is also, it seems, good for the brain."