A study of the game PIG can be introduced to high school or first year undergraduate students as an interesting case for the study of decision making based on ''mathematical thinking''. When a player is playing a match of this game with an opponent, at each step in the game he or she has to decide whether to ''continue'' or to ''stop''. Students can learn to develop a strategy for making such a decision, based on the ''expected gain'' and related probabilities. The strategy should also involve the examination of the total score earned from previous games as well as a comparison with the opponent's score. The purpose of this paper is to help teachers to show students how such a strategy may be developed. This study will provide students with a good example of solving problems with mathematical thinking. It can also be an interesting computer programming exercise for them to code the strategy into a computer program and see how a computer can help in decision making.