Mattis is hosting a badminton tournament for $40$ players on $20$ courts numbered from $1$ to $20$. The players are distributed with $2$ players on each court. In each round, a winner is determined on each court. After each round:

1. The player who lost on court $1$ and the player who won on court $20$ remain in their respective positions.
2. For the remaining $38$ players:
   - The winner on court $i$ moves to court $i + 1$.
   - The loser moves to court $i - 1$.

The tournament continues until every player has played every other player at least once. What is the minimal number of rounds the tournament can last?

Let's think step by step and output the final answer within \boxed{}.
user