Backcourt violations occur in almost every single game. Awarding the ball to the other team is no problem, but too often, it is awarded at the wrong spot.
It isn’t uncommon to hear a new official ask, “On a backcourt violation, where does the spot throw-in occur?” I think I even asked this question when I was new as well.
The penalty portion of Rule 9.9 – Backcourt states, “The ball is dead when the violation occurs and is awarded to the opponents for a throw-in from the designated out-of-bounds spot nearest the violation.” (NFHS Basketball Rules Book).
The backcourt violation does not occur when the ball crosses over the mid-court line, the violation occurs when a player is the first player to touch the ball after it has been in team control in their front court. So, when the ball rolls all the way down to the end-line before it is touched, it is awarded to the team on the end-line.