Let $m$ and $n$ be positive integers and $p$ be a prime number. Find the greatest positive integer $s$ (as a function of $m,n$ and $p$) such that from a random set of $mnp$ positive integers we can choose $snp$ numbers, such that they can be partitioned into $s$ sets of $np$ numbers, such that the sum of the numbers in every group gives the same remainder when divided by $p$.
Problem
Source: 2022 Bulgarian Spring Math Competition, Problem 12.4
Tags: number theory, prime numbers, abstract algebra