Past questions › sample-q11
2025 3 marks Short answer The Software Engineering Project (Year 12) Testing (test data)
NESA HSC Software Engineering Sample Examination + Marking Guidelines (official, 2025)
Algorithm: BEGIN responsiveScreen / Get ScreenSize / IF ScreenSize >= 1024 THEN Viewport = 'Desktop' / ELSEIF ScreenSize >= 768 THEN Viewport = 'Tablet' / ELSE Viewport = 'Phone' / ENDIF / Display "Display set to ", Viewport / END. Provide a set of test data that will thoroughly test the algorithm. Include expected outputs and reasons for inclusion. (Table: Test data (ScreenSize), Expected output (Viewport), Reason for inclusion; 3 rows shown.)
Marking criteria
3: Test data that thoroughly tests the algorithm, with expected outputs and reasons. 2: Tests most of the boundaries and paths, with relevant outputs and reasons. 1: Some relevant information.
Sample answer
1024 -> Desktop (boundary check). 768 -> Tablet (boundary check). 100 -> Phone (below lowest screen size check). 850 -> Tablet (between Tablet and Desktop). 2000 -> Desktop (above highest screen size check).