Count of Matches in Tournament

EasyMathSimulation

Solution

export function numberOfMatches(n: number): number {
  /**
   * As n - 1 teams will be eliminated, there will be n - 1 matches played,
   * with each match eliminating a team.
   */
  return n - 1;
}