A study of Olympic athletes shows the surprising benefits of coming in second place