Computer Science (0478) · Oct/Nov 2016 · Mark scheme 21
Cambridge Computer Science (0478) mark scheme for paper 21, Oct/Nov 2016 — 0478/21/O/N/16, file 0478_w16_ms_21.pdf.
Text of this paper
www.dynamicpapers.com
Cambridge International Examinations
Cambridge International General Certificate of Secondary Education
COMPUTER SCIENCE
0478/21
Paper 2
October/November 2016
MARK SCHEME
Maximum Mark: 50
Published
This mark scheme is published as an aid to teachers and candidates, to indicate the requirements of the
examination. It shows the basis on which Examiners were instructed to award marks. It does not indicate the
details of the discussions that took place at an Examiners’ meeting before marking began, which would have
considered the acceptability of alternative answers.
Mark schemes should be read in conjunction with the question paper and the Principal Examiner Report for
Teachers.
Cambridge will not enter into discussions about these mark schemes.
Cambridge is publishing the mark schemes for the October/November 2016 series for most
®
Cambridge IGCSE , Cambridge International A and AS Level components and some Cambridge O Level
components.
® IGCSE is the registered trademark of Cambridge International Examinations.
This syllabus is approved for use in England, Wales and Northern Ireland as a Cambridge International Level 1/Level 2 Certificate.
This document consists of 5 printed pages.
© UCLES 2016
[Turn over
Page 2
www.dynamicpapers.com
Mark Scheme
Cambridge IGCSE – October/November 2016
Syllabus
0478
Paper
21
Section A
1
(a) Many correct answers, the identifiers must be meaningful. These are examples only.
There are two marks available for each identifier:
• 1 mark for suitable name
• 1 mark for a suitable data structure, data type and use
– MaxVotes, constant, integer, maximum number of votes that can be cast
– CandidateName, array, string, name of candidate
– NoCandidates, variable, integer, number of candidates
– TotalNoCandidateVotes, array, integer, total number of votes cast
[8]
(b) Any four from:
– prompt for input of candidate number
– input of candidate number
– check for candidate number of 1, 2 or 3
– output ‘invalid vote’ if input not 1, 2, or 3
– otherwise add 1 to appropriate total and …
– … output name of candidate voted for
[4]
(c) Description (may include reference to programming statements) any six marks from
– output total and …
– … corresponding candidate name...
– description of method for selecting descending order of totals
– evidence that the method works
– check if highest number of votes is a unique value
– if unique output the candidate name and ‘NEW CLASS CAPTAIN’
– otherwise output ‘NO OVERALL WINNER’
[6]
(d) Accept any reasonable suggestion(s), two marks can be awarded for either a suggestion with
an accompanying description e.g.
– re run the voting (1) without the least popular candidate (1)
or accept two different suggestions e.g.
– re run the voting
– give the teacher the casting vote.
© UCLES 2016
[2]
www.dynamicpapers.com
Page 3
Mark Scheme
Cambridge IGCSE – October/November 2016
Syllabus
0478
Paper
21
Section B
2
(a) 1 mark for each change
– Line 2: OutRange = 0
– Line 6: should be OutRange = OutRange + 1
– Line 7: not needed
– Line 8: NEXT X should be NEXT Count / Line 3: FOR Count = 1 TO 10 should be
FOR X = 1 TO 10
[4]
(b)
Number
Within
range (9)
Outside
range (9)
Reason
10
9
Range greater than 10, so 10 not included
20
9
Range less than 20, so 20 not included
[4]
3
Price
Change
Dollars
TenCents
OUTPUT
6.29
3.71
3
0.71
3 dollars
0.21
One 50 cent coin
2
2 ten cent coins
One 5 cent coin
(1 mark per correct column)
[5]
© UCLES 2016
Page 4
4
www.dynamicpapers.com
Mark Scheme
Cambridge IGCSE – October/November 2016
Syllabus
0478
Paper
21
1 mark for each correct link up to maximum of 3 marks
[3]
5
For each example 1 mark for correct structure, 1 mark for appropriate content inside loop and
1 mark for reason. There are many correct answers these are only samples
REPEAT
..INPUT Number
Total ← Total + Number
UNTIL Number = 0
– at least one repeat is required
6
WHILE Number <> -1 DO
..INPUT Number
Total ← Total + Number
ENDWHILE
– the loop may never be executed
[6]
(a) –
–
Town has duplicate entries/all fields can have duplicate entries
fields other than Town not suitable identifiers
[2]
(b) –
–
Performance number …
… uniquely identifies each performance
[2]
© UCLES 2016
www.dynamicpapers.com
Page 5
Mark Scheme
Cambridge IGCSE – October/November 2016
Syllabus
0478
Paper
21
(c)
Field: Town
Table: THEATRETOURS
Tour Date
Price Local
Currency
THEATRETOURS
THEATRETOURS
;
;
Sort: Ascending
Show:
;
Criteria:
or:
1 mark for each column + 1 mark for correct fields only
© UCLES 2016
[4]