2026 JPJC Computing Prelim P1 markscheme
Uploaded by Kozak327 · 4 October 2026
Preview
Text from the first pagesJurong Pioneer Junior College 2026 H2 Computing Paper 1 (Syllabus 9569) Suggested Solutions & Marks Scheme (v13) 1 (ai) ClassParticipation(studentID, studentName, courseID, courseName, sessionID, sessionDate, startTime, deliveryMode, enrolDate, status, joinTime, punctuality) 2m – all attributes from the scenario listed and composite primary key (studentID, sessionID) identified. Also accept (studentID, courseID, sessionID) as the key. SR: minus 1m for each missing or wrong key attribute, minus 1m if attributes from the scenario are omitted (minimum 0m). (aii) Using a single 1NF table causes data redundancy. For example (any one of the following): The same student details (name) are repeated for every course and session they attend. The same course details (name) are repeated for every session and for every student enrolled in that course. The same session details (date, start time, delivery mode) are repeated for each student attending that session. The same enrolment details (enrolment date, status) are repeated for every session of that course the student attends. OR Using a single 1NF table leads to anomaly. For example (any one of the following): Update anomalies Updating a student’s name or a course’s name requires changes in many rows. Missing one update leads to inconsistent data. Insertion anomalies A new course or session cannot be added to the table before any student has attended it, without creating a dummy participation row. Deletion anomalies Deleting the last row for a course or session could unintentionally remove all information about that course or session.
2 1m – identification of one limitation 1m – explain/expand on the limitation phrased in question’s context (aiii) 1m – all entities identified correctly 2m – all relationships between 2 entities are correct SR: minus 1m for each relationship or entity shown incorrectly (minimum 0m). Expected: five one-to-many relationships, Student to Enrolment, Course to Enrolment, Course to Session, Student to Attendance, Session to Attendance. (aiv) STUDENT(studentID, studentName) COURSE(courseID, courseName) SESSION(sessionID, courseID, sessionDate, startTime, deliveryMode) ENROLMENT(studentID, courseID, enrolDate, status) ATTENDANCE(studentID, sessionID, joinTime, punctuality) 1m – all tables & PKs identified 1m – all FKs identified: courseID in SESSION; studentID and courseID in ENROLMENT; studentID and sessionID in ATTENDANCE (shown above with double underline, meaning both PK and FK; candidates should show solid plus dashed underline) 1m – composite primary keys for ENROLMENT and ATTENDANCE tables (SESSION has the single-attribute key sessionID) (bi) SELECT s.studentID, COUNT(a.sessionID) AS totalSessionsAttended FROM Student AS s, Enrolment Student Course Attendance Session
3 Attendance AS a WHERE s.studentID = a.studentID GROUP BY s.studentID; 1m – SELECT studentID and COUNT(...) of sessions 1m – FROM Attendance, with or without a join to Student (a correct answer using only the Attendance table, e.g. SELECT studentID, COUNT(*) FROM Attendance GROUP BY studentID, earns full marks) 1m – GROUP BY studentID (bii) SELECT s.studentID, s.studentName, COUNT(a.sessionID) AS attendanceCount FROM Student AS s, Attendance AS a WHERE s.studentID = a.studentID GROUP BY s.studentID, s.studentName ORDER BY attendanceCount DESC LIMIT 3; 1m – SELECT studentID, studentName and COUNT(...) with Student joined to Attendance on studentID 1m – GROUP BY studentID, studentName 1m – ORDER BY the count in descending order and LIMIT 3 (accept TOP 3, FETCH FIRST 3 ROWS ONLY; accept ORDER BY COUNT(*) DESC) (ci) Either of the following: Unlike relational databases, NoSQL systems (e.g., MongoDB) can scale horizontally. The huge write loads, as more users stream classes, can be distributed across many low-cost, lower-end servers. The flexible schema allows new fields such as additional device or network metrics to be added without altering a rigid relational schema or performing costly migrations.
4 1m – for identification of advantage 1m – for explaining the advantage (cii) A relational database is still preferable for JPStream when storing structured, business-critical data such as student enrolments, course information, and official attendance records. These require strict referential integrity to ensure correctness. 1m – type of data 1m – why the type of data requires RDBMS
5 2 (a) Class diagram [8m] Superclass: Vehicle - registrationNumber : String - status : Boolean - distanceTravelled : Integer - efficiencyScore : Integer + Vehicle(reg : String) + IsActive() : Boolean + GetEfficiency() : Integer + CalculateEfficiency() : Integer Subclasses (each inherits from Vehicle — shown with a hollow-headed arrow pointing up to Vehicle): Van - fuelUsed : Integer + CalculateEfficiency() : Integer Motorbike - fuelUsed : Integer + CalculateEfficiency() : Integer Bicycle (no additional attributes) + CalculateEfficiency() : Integer Notes on the diagram: Van and Motorbike inherit registrationNumber, status, distanceTravelled and efficiencyScore from Vehicle — these are not repeated in the subclasses. Each subclass overrides CalculateEfficiency() with its own formula (this is the polymorphism referred to in part (c)(iii)). Bicycle has no additional attributes but still overrides CalculateEfficiency() since its efficiency score changes differently (+1). Any equivalent, sensible naming and layout showing the same structure is acceptable. Mark Scheme (8m): 1m – Vehicle superclass named and drawn as a class box 1m – Van, Motorbike and Bicycle subclasses 1m – inheritance shown with arrows from each subclass to Vehicle 1m – four superclass attributes (registrationNumber, status, distanceTravelled, efficiencyScore)
6 with sensible data types; accept status as String or Boolean 1m – fuelUsed attribute in Van and Motorbike only, none in Bicycle 1m – constructor and/or getter/setter methods in Vehicle 1m – CalculateEfficiency() declared in Vehicle and overridden in each subclass 1m – method that sets status to inactive when efficiencyScore is 0 or less (e.g. UpdateStatus() or IsActive()) Note: the motorbike rule in the paper can be read as distance - fuel x 3 or as (distance - fuel) x 3. Accept either reading here and in (c)(iii). (b) Instantiation [1m] Instantiation is the process of creating an actual object from a class — that is, using the class as a template/blueprint to create a specific object with its own values for the attributes defined in the class (e.g. creating a specific Van object with registration number “SBA1234A”).
7 (c)(i) Encapsulation [2m: 1m definition, 1m example from the simulation] Encapsulation is the bundling of data (attributes) and the methods that operate on that data within a single class, and restricting direct access to that data from outside the class (data hiding). Example: in the simulation, efficiencyScore is declared as a private attribute. It cannot be changed directly by code outside the class; it can only be updated by calling the class's own CalculateEfficiency() method, which ensures the value is always changed in a controlled, valid way. (c)(ii) Inheritance [2m: 1m definition, 1m example from the simulation] Inheritance is a mechanism where a subclass automatically acquires (inherits) the attributes and methods of its superclass, so they do not need to be redefined in each subclass. Example: Van, Motorbike and Bicycle all inherit registrationNumber, status, distanceTravelled, efficiencyScore and methods such as IsActive() from the Vehicle superclass, so this shared code only has to be written once. (c)(iii) Polymorphism [2m: 1m definition, 1m example from the simulation] Polymorphism is the ability for a method with the same name to behave differently depending on which class (object) it is called on
Content continues in the PDF. Download PDF
Related notes
- NYJC 2026 Prelim P2Exam Papers · 2026
- NYJC 2026 Prelim P1Exam Papers · 2026
- DHS 2026 Y6 H2 Computing Prelim Paper 2_finalExam Papers · 2026
- ACJC 2026 JC2 Computing Prelim Paper 2 (Practical)Exam Papers · 2026
- 2026_NJC Prelim_Computing_P2.pdfExam Papers · 2026
- 2026_JPJC_Computing_Prelim_P2_finalExam Papers · 2026
- 2026_JPJC_Computing_Prelim_P1_finalExam Papers · 2026
- 2026 ACJC Prelim Computing Paper 2Exam Papers · 2026
- 2024 ACJC Computing PromoExam Papers · 2024
- 2023 ACJC Promo QPExam Papers · 2023
- 2022 ACJC Computing Promo Paper 2Exam Papers · 2022
- 2021 ACJC Computing Promo Paper 2Exam Papers · 2021
- See all H2 Computing notes

