According to Newton's third law, for every action force there is a reacgtion force, then how can a team win a tug of war contest

The two teams exert different forces on each other, but matters is the net force on each team. The winning team is able to generate a larger backward force upon itself at the ground (with their feet) than the other team is able to exert on them.

I meant to say just the opposite in the first sentence..

"The two teams exert equal and opposite forces on each other" . The rest is OK

In a tug of war contest, the team that wins is the one that can exert a greater force in pulling the rope towards their side. This may seem contradictory to Newton's third law, where every action has an equal and opposite reaction. However, the key to understanding this is to consider the different systems involved.

When one team pulls on the rope, they exert a force on it, which is the action force. According to Newton's third law, there is indeed a reaction force, which is equal in magnitude but opposite in direction. This reaction force occurs on the pulling team itself, causing them to be pulled backward.

However, the action-reaction forces in this case are acting on different systems. The action force is being applied to the rope, while the reaction force is being applied to the team. The team can brace themselves and use their weight, strength, and teamwork to resist the reaction force and prevent themselves from being pulled backward. By doing so, they apply a greater force on the rope than their opponents, causing the rope to move in their desired direction and winning the contest.

So, even though Newton's third law states that every action has an equal and opposite reaction, in a tug of war contest, it is the ability of the team to resist and overcome the reaction force that determines the winner.