Courses with seat limits and prerequisite chains: students record completions, enrol, drop and wait in line, and an eligibility check explains why a student cannot get in.
01Create courses with a code, a title, a seat limit, a drop deadline and prerequisite courses; read a course and replace its prerequisites.
02Create students and record the courses they have completed.
03An eligibility route says whether a student can enrol, why not, and which prerequisites are missing.
04Enrol an eligible student in a free seat, or on the waitlist when the course is full; drop a student from a course.
05400 for invalid input, 404 for an unknown course or student, 409 when the student cannot enrol.
What the hidden tests check
Everything the interviewer tells you is checked.
Seat and waitlist order are checked after every drop, and prerequisite chains several courses deep are checked.
4 more details are held back. In a mock interview they come out only when you ask the interviewer the right question; in practice they are listed in the workspace.