A lot of teachers look at children who fidget during class and assume they’re not paying attention. But it turns out the exact opposite may be the case. New research has found that, for children with attention deficit hyperactivity disorder (ADHD), fidgeting may have a positive affect on working memory.

In a study soon to be published in the Journal of Attention Disorders (and available online now, behind a paywall), researchers from Florida State University devised memory and information ordering tests of various difficulties. 25 children with ADHD, ages 8 to 12, then took the tests, which predominantly involved ordering strings of letters, numbers, and colored dots. Researchers found that children squirmed up to 25 percent more during tests where they were not told in advance how many items they would have to remember. 

Researchers believe that these results show that, for children with ADHD, squirming is directly linked to working memory processes—that is, the active ordering or updating of information in their minds. “It’s another piece of evidence that the hyperactive behavior more and more seems to be purposeful for them,” says researcher Michael Kofler in a statement. “This movement is how they get the juices flowing.”

Not only should the study—which is one of several small studies in the past year to find a connection between movement and learning in kids with ADHD—help dispel the belief that a fidgeting child is necessarily an inattentive child, but researchers hope it will help them develop ADHD treatments in the future.

“Our work keeps pointing to working memory,” says Kofler. “It affects their attention, their impulse control, their school success, their social interactions and now their hyperactivity. So we’re going to try and improve working memory. This is a challenge, but if we’re successful, we should see better attention and impulse control, and they shouldn’t have to move as much.”