An algorithm is represented using pseudo-code below:
1 systolic ← USERINPUT
2 diastolic ← USERINPUT
3 IF systolic >= 140 THEN
4 high_pressure ← TRUE
5 ENDIF
6 IF high_pressure AND diastolic >= 90 THEN
7 OUTPUT "Hypertension Alert"
8 ELSEIF diastolic < 60 OR systolic < 90 THEN
9 OUTPUT "Hypotension Alert"
10 ENDIF
Where is a logical operator first used in this algorithm?
Line 3\text{Line 3}Line 3
Line 4\text{Line 4}Line 4
Line 6\text{Line 6}Line 6
Line 8\text{Line 8}Line 8
Practise AQA GCSE Computer Science Boolean operations in a programming language with exam-style questions for GCSE Computer Science. 19 questions, matched to the AQA GCSE Computer Science (8525) specification and written in Paper 1 and Paper 2 style. Every question includes a full worked solution and mark scheme, so you can see where marks are awarded rather than just whether you got the answer right.