When and why do retrieval attempts enhance subsequent encoding?