The main scenario in basketball where a 3-on-2 would occur is a fast break where the defensive team is left at a disadvantage. 3 offensive players are able to attack only 2 defensive players for a short time, giving them a mismatch that can be exploited to their offensive benefit. The goal of the 2 defenders is to prevent the offense from scoring long enough for the rest of their teammates to recover and help them out. In a more minor scenario, coaches may use 3-on-2 drills in both the full and half court to strengthen different parts of their team.
The offense is given this man-up opportunity usually for only a short amount of time before the rest of the players are able to recover. Quick ball movement among the 3 offensive players should result in a good shooting opportunity whether it comes from inside the paint or an outside shot. Keeping the ball in the middle of the floor as much as possible allows for more offensive options leading to better scoring as the defense must move both left and right instead of just one direction.
The defense must compensate for their disadvantage by stalling the offense as long as possible, and if they cannot prevent a shot from occurring, they must cause the least efficient opportunity for the offense that they can. The key to lowering the chances of scoring for the defense is forcing the ball to one side of the court making it easier to defend all 3 players at once instead of being spread out across the entire court. Keeping the offense to the sides and contesting every shot will give the defense the best opportunity possible to prevent the offense from scoring.