According to some psychological research, silver medalists in a competition are less happy than bronze medalists; and that is true of even silver medalists in the Olympic Games. If this is a true phenomenon, it cannot be explained simply by the fact that we evaluate ourselves in terms of comparison, for the silver medalist should feel good by comparing himself with the bronze medalist. One plausible explanation is that the silver medalist is influenced by counterfactual thoughts, more specifically, the counterfactual thought that he might have won the gold medal.
But why isn't the counterfactual thought the one that he might have got only the bronze medal? This is, I think, because the silver medalist is compelled by his wish to win the gold medal to focus on it rather than the bronze medal. And wishful thinking may be working here, for the silver medalist may believe that he could easily have won the gold medal ("I was so close", "I was just having bad luck", etc.).
What about the bronze medalist? Why doesn't he feel unhappy because he has not won the silver medal? Unlike the silver medalist, who would still have won a medal, namely, the bronze one, even if he had lost to the bronze medalist, the bronze medalist would have got nothing if he had not performed as well as he did. So, in his case, the most compelling counterfactual thought is the one that he might easily have got nothing.