The latest research seems to show that some type of aerobic activity (walking, running, etc.) before cognitive activity can improve both our short- and long-term memory function. And it does not have to be vigorous exercise to be beneficial. Also, other studies of older adults show a decreased likelihood of developing dementia if we stay relatively active rather than sedentary. Check out this link for a brief explanation.