Studying Strategically: Learning to Mask for Closed-book QA