Leveraging Training Data in Few-Shot Prompting for Numerical Reasoning