Past-paper question · 2016 October-November · Paper 23 · Q12

Question 12 2016 · October-November · Paper 23 · 14 marks

Original past-paper question for 12
Original past-paper question for 12
Reveal official mark-scheme answer Official mark-scheme answer for 12Official mark-scheme answer for 12

Official answer for Question 12

✓
Note: Order of 11, 10
✓
and 7,8 may be
✓
No
✓
reversed.

Mark scheme 9608_w16_ms_23.pdf →

Show text version of question

Question 12

Is TicketType = 'E' ?

Complete the flowchart by putting the appropriate statement number in each flowchart symbol. Statement 5 has been done for you.

Question 3

Start

Question 5

Stop

[6]

Question 4

Part (b)

The programmer needs data to test the flowchart.

Complete the table of test data below to show five tests.

TicketType BaggageWeight Explanation Expected output

................................................................. E 15 .................................................................

.................................................................

.................................................................

.................................................................

.................................................................

.................................................................

.................................................................

.................................................................

.................................................................

.................................................................

.................................................................

.................................................................

.................................................................

.................................................................

[5]

Question 5

Part (c)

The program design is to be amended. The value input by the user for the ticket type is to be

validated. Part of the amended flowchart is shown below.

Start

Loop

INPUT TicketType

Is TicketType No E or S ?

Yes

Write pseudocode to use a pre-condition loop for this validation.

...................................................................................................................................................

...................................................................................................................................................

...................................................................................................................................................

...................................................................................................................................................

...................................................................................................................................................

...............................................................................................................................................[3]

Question 6

2 A sensing device sends bit values to a computer along data channels.

  • Channel 1 transmits a sequence of binary values from a sensor
  • Channel 2 transmits at regular intervals to indicate whether the sensor is switched on or off:
  • 0 indicates switched off
  • 1 indicates switched on
A
program tests the bits received from the sensing device.
A
program reads the signal from Channel 2 after every six values from Channel 1.
A
built-in function READ(<ChannelNumber>) reads a value from the specified channel.

Pseudocode for the program is as follows:

01 BitCount 0 02 Status2 READ(2) 03 WHILE Status2 = 1 04 05 FOR ReadingCount 1 TO 6 06 ThisBit READ(1) 07 IF ThisBit = 1 08 THEN 09 BitCount BitCount + 1 10 ENDIF 11 IF BitCount = 5 12 THEN

Topic relevance

Why this question appears here

82% assigned-topic match · Programming › Constructs

Topic-match percentages estimate how closely each question fits the selected syllabus topic. They are a guide for choosing stricter or broader practice.

Permanent source page: Educate A Change · From 9608_w16_qp_23.pdf

Keep practising this topic