0% found this document useful (0 votes)
219 views

Y10 04 CT24 Assessment

Assessment

Uploaded by

molaposk10
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
219 views

Y10 04 CT24 Assessment

Assessment

Uploaded by

molaposk10
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

TOPIC 1: COMPUTATIONAL THINKING

Assessment

ASSESSMENT Y10-04-CT24

Name ____________________________________________ Date __________________

Question 1
Define the term ‘array’. (1)

……………………………………………………………………………………………….................

Question 2
Define the term ‘record’. (2)

……………………………………………………………………………………………….................

Question 3
State the name of the data structure Python uses to implement an array and a record. (1)

……………………………………………………………………………………………….................

Question 4
Here is a table of records named ‘table’, which is stored in a two-dimensional data structure
in a program.
Name Writer Code Price
Sunshine Met Office 83941 12.86
High Rise Builder Brigade 4852 23.76
Rough Seas Sammy the Sailor 75219 18.34
Sweet Dreams Bed Builder 368 19.33

a State the number of records in the table. (1)


……………………………………………………………………………………………….................

b Write an expression to identify the record for ‘Sunshine’. (1)


……………………………………………………………………………………………….................

c Write an expression to identify the field for ‘Sammy the Sailor’. (1)
……………………………………………………………………………………………….................
© Pearson Education Ltd 2020. Copying permitted for purchasing institution only. This material is not copyright free.
1
TOPIC 1: COMPUTATIONAL THINKING

Assessment

Question 5
A user enters a year of birth, for example, 1999 or 2018. The rules for validation are:
 it is present
 it is exactly 4 characters in length
 years should start 20 or 19 only
 users cannot be younger than 16.

Open ‘Question5_Student.py’ in your programming environment.


Complete each of the ‘if statements’ to provide a validation check.
Do not change any other code.
Hints:
 if you can’t get one to work, comment it out and adjust indentation
 the third test uses slicing [0:2] to get the first two characters of the input string
 leave the user input as a string until the fourth test.
(7)

Question 6
Information about this year’s school trips has been stored in a two-dimensional data
structure. Open ‘Question6_Student.py’ in your development environment.
Complete the ‘displayTrips()’ subprogram to show the trip information.
Do not add any other functionality or change any other part of the supplied code.
The output should be formatted so that it fit for purpose and suitable for the audience. An
example output is shown. Spacing does not have to be exact.

(6)

© Pearson Education Ltd 2020. Copying permitted for purchasing institution only. This material is not copyright free.
2
TOPIC 1: COMPUTATIONAL THINKING

Assessment

Question 7
Arrange the flowchart symbols to represent a generic linear search algorithm.
 Use each symbol only once.
 Do not add any symbols.
 Use as many arrows and labels as required.

Draw your flowchart in the space provided. (8)

© Pearson Education Ltd 2020. Copying permitted for purchasing institution only. This material is not copyright free.
3
TOPIC 1: COMPUTATIONAL THINKING

Assessment

Question 8
Information about next year’s school trips has been stored in a two-dimensional data
structure.
Open ‘Question8_Student.py’ in your development environment.
Complete the ‘findByCode()’ subprogram to find the information about a trip code entered by
the user.
Add comments to explain your logic.
No validation of user input is required.
Do not add any other functionality or change any other supplied code. (10)

Total marks: 38

© Pearson Education Ltd 2020. Copying permitted for purchasing institution only. This material is not copyright free.
4

You might also like