That's right. When things are difficult we learn more. So say the scientists behind a study that compared the effect of fonts on the participants ability to recall studied material in an exam. The experiment had half the participants read text in 16-point Arial font and the other half in 12-point Comic Sans MS or 12-point Bodoni MT. These last two were deemed to be harder to read fonts. Those participants who studied the material in the more unfamiliar fonts did better on their exams. Why? Because their brains had to work harder to process the material. The finding: "difficulty builds mental muscle, while ease often builds only confidence."
Further: “For example, we know that if you study something twice, in spaced sessions, it’s harder to process the material the second time, and people think it’s counterproductive,” said Nate Kornell, a psychologist at Williams College. “But the opposite is true: You learn more, even though it feels harder. Fluency is playing a trick on judgment.”