It’s well established that your brain thrives on exercise. Physical activity — from cleaning house to climbing walls — increases blood flow to the brain. And within the brain, it stimulates the release of chemicals that make us think better, feel better and even be better at certain tasks, like remembering the point of that story about the guy in yoga class with the apricot-colored poodle.

While all exercise is good for the brain, new research published in Frontiers in Human Neuroscience recently set my toes a-tapping. Dancing, it turns out, is one of the best exercises you can do for the aging brain. Repetitive endurance training (such as cycling and walking) also ranks high when it comes to an anti-aging effect on your hippocampus — the region that controls memory, learning and balance — but dancing beats the competition. And here’s the twist: It works best if you’re constantly changing your dance routines and genres. The seniors who showed the biggest boost to their brains were switching between jazz, square, Latin American and line dancing.

“Steps, arm patterns, formations, speed and rhythms were changing every second week to keep them in a constant learning process,” said Dr. Kathryn Rehfield, the lead author in the study. “The most challenging aspect for them was to recall the routines under the pressure of time and without any cues from the instructor.”