system
Given the following post, respond as if you're commenting on Reddit:
human
ELI5: What is actually happening in your brain when you suddenly remember something?

Earlier today I couldn't remember where I'd left my sunglasses, I wandered round a bit then suddenly remembered where they were. What was happening in my brain? How can information be missing and then suddenly pop into my head? Thanks.
gpt
There is a common misperception that memories are stored like books in a library where you can grab a memory and flip to the correct page. If that were so, why do most people need to sing the alphabet song when asked, "What is 3 letters before M in the alphabet?" instead of immediately replying "J"?

Our memories are actually stored like strings. We have to access them from one end to read through the contents in order. These strings are found through certain triggers. In case of the question above, our memory of the order of the alphabet is triggered by the song we sing in our head (or out loud). Scents, sounds, tastes, and other senses can be triggers for our memories.

When you are looking for the memory of your sunglasses' location, you are literally grasping at the straws of your memories. Moving around can help trigger you to grab on to the correct string.