The Effect of Sampling Temperature on Problem Solving in Large Language Models