Answer:
Praise be to Allah, the Lord of the Worlds; and may His blessings and peace be upon our Prophet Muhammad and upon all his Family and Companions.
If the situation is as you described in your question, then this is a prize and it is lawful as long as it is for encouragement and provided those who participated were students whose primary aim was to study. Those who paid such fees to these centers only for the aim of getting the prize, then what they did was unlawful as this is like gambling.
So, the Shari'a rule depends on the students' intention and objective. One indication that what is done is gambling (not prizes) is the high fees in these centers compared to other centers of similar quality and similar capabilities.
Allah knows best.