It is not always possible to win in life, sometimes you have to accept defeat. Many do not know how to lose. They start to worry and get upset. Learning to accept defeat is difficult; it is, so to speak, a whole art.
Of course, winning is always preferable to losing. However, sometimes defeat can be beneficial. The main thing here is to look at situations from the right angle. An emotional crisis is indispensable; it always accompanies failure. However, when it passes, it is worth analyzing the situation and looking for positive moments.
Remember that not all losses are so important. Most likely, your situation is not critical. Perhaps you have a chance ahead of you to fix everything and win.
If your opponent won the victory unfairly, remember that the earth is round and any bad deeds will return to the person. Who knows, perhaps your opponent will lose more in the future than you this time.
You can, on the contrary, consider a pessimistic option. Then evaluate your defeat as a punishment for bad actions from the past, or accept the idea that there is no justice in life and the world is too cruel.
Try to push the experience aside. Get distracted. Think about something pleasant. Take a walk with friends, go to computer games. The main thing is not to think about the problem.
Write a plan for at least a week. Then you will be busy with business and forget about the problem.
Remember that over time, all emotions will subside. And, perhaps, your loss will seem insignificant and not affecting your life in any way, or maybe it will bring you benefit and new opportunities, because everything in life is relative.