Probiotics and prebiotics can help in maintaining a healthy gut-brain axis by promoting the growth of beneficial bacteria in the gut, which in turn can positively impact memory development.