Welcome to Hawk High, enroll, avoid bad reviews, and graduate!!!
You have been contracted to review the upgradeable contracts for the Hawk High School which will be launched very soon.
These contracts utilize the UUPSUpgradeable library from OpenZeppelin.
At the end of the school session (4 weeks), the system is upgraded to a new one.
Principal: In charge of hiring/firing teachers, starting the school session, and upgrading the system at the end of the school session. Will receive 5% of all school fees paid as his wages. can also expel students who break rules.Teachers: In charge of giving reviews to students at the end of each week. Will share in 35% of all school fees paid as their wages.Student: Will pay a school fee when enrolling in Hawk High School. Will get a review each week. If they fail to meet the cutoff score at the end of a school session, they will be not graduated to the next level when thePrincipalupgrades the system.
- A school session lasts 4 weeks
- For the sake of this project, assume USDC has 18 decimals
- Wages are to be paid only when the
graduateAndUpgrade()function is called by theprincipal - Payment structure is as follows:
principalgets 5% ofbursaryteachersshare of 35% of bursary- remaining 60% should reflect in the bursary after upgrade
- Students can only be reviewed once per week
- Students must have gotten all reviews before system upgrade. System upgrade should not occur if any student has not gotten 4 reviews (one for each week)
- Any student who doesn't meet the
cutOffScoreshould not be upgraded - System upgrade cannot take place unless school's
sessionEndhas reached
Check out this to learn more about Upgradeable Contracts
├── src
│ ├── LevelOne.sol
│ └── LevelTwo.sol
- Chain: EVM Compatible
- Token: USDC
git clone https://github.com/CodeHawks-Contests/2025-05-hawk-high.git make setup forge build forge testNone reported! 😉