← All Assignments
Design an Online Exam Portal
Problem Statement
Design a simple online exam portal for your college. Features needed: - Students log in and take a multiple choice exam - Each exam has a time limit (e.g. 30 minutes) - Results are shown immediately after submission - Teachers can see all student scores Write your design covering: 1. Database schema (tables for users, exams, questions, submissions) 2. How do you enforce the time limit? 3. How do you prevent students from seeing each other's answers? 4. How is the score calculated automatically? 5. What would break if 500 students take the exam at the same time?
Sample Data
No code required — write your design as text or pseudo-code. Think about: - What data needs to be stored - What happens step by step when a student submits - What the teacher's view looks like
Expected Output
Schema: users, exams, questions, student_answers tables Time limit: store start_time, check elapsed on submit Security: each student only queries their own answers Auto score: compare student answers to correct_answer column Scale concern: DB writes spike, consider queuing submissions