Problem

Source: 2024 Azerbaijan BMO TST

Tags: combinatorics, AZE BMO TST, TST



Let $n$ be a positive integer. Using the integers from $1$ to $4n$ inclusive, pairs are to be formed such that the product of the numbers in each pair is a perfect square. Each number can be part of at most one pair, and the two numbers in each pair must be different. Determine, for each $n$, the maximum number of pairs that can be formed.