Memory helps, but it is definitely not the same thing as intelligence. A simple example would be with the quadratic forumla. Memory is just being able to recite it without looking it up, but intelligence would be knowing what it means, how to use it, and likely being able to derive it. In fact, this is one of my biggest complaints about our public education system, is that so much of it is just straight memorization, but there’s less concern about actually understanding it.
Anyway, even with that differentiation, there’s often a correlation between intelligence and memory because an intelligent person will exercise his memory because it’s advantageous, he probably has an interest in learning new things and a certain minimum amount is straight up necessary and I’d imagine that minimum amount is higher as intelligence gets higher, at least to reasonably apply it.
I agree that memory is helpful but that intelligence is seeing how the facts you remember are interconnected. When I taught data structures I had some test questions that were memory based, like on sorting algorithms, and some which were understanding based, like more or less essay questions on data structures. It was a good way to sort the intelligent from the less intelligent from those who didn’t even try to memorize the stuff.
As I age, my long-term memory is increasing, while my short-term is decreasing. I can remember more from my childhood than I ever previously remembered, and these memories have been corroborated by older relatives.
For me, I have seen a distinction between what I call “brains” and what I can “intellect”.
I have met people who are very smart, have high IQs, analytical, great recall for facts, reach effective conclusions - but they have no intellectual subtlety or curiosity. I have often observed these people in leadership roles. They don’t read (or have a desire to read), don’t have any interest in anything resembling culture (high or low), don’t posses creativity, are unversed in philosophical concepts and human behavioral psychology, etc. To me they have “brains” but lack “intellect”.
Especially by the high school level, many tests are requiring more than recall. For example, there are essay portions of the tests that will ask things like “Compare and contrast the ways that Hitler and Stalin obtained and kept power.” If all you can do is recite facts, you can’t get an ideal score on a question like that because it calls for analysis and processing of the information. You need to have some facts memorized, of course, so those who do best on these exams will excel in a combination of traits.