In a tournament there are teams and each team plays each other team twice. A team gets two points for a win, one point for a draw and no points for a loss.
With two teams there are three possible outcomes for the total points. where a team wins twice, where a team wins and draws, and where either there are two draws or a team wins one game and loses the other. Here we do not distinguish the teams and so and are considered identical.
Let be the total number of possible final outcomes with teams, so that .
You are also given .
Find . Give your answer modulo .
Write-up coming later
The complete problem is available here. An approach, code, and answer will be added later.