The subroutine SLICER extracts characters from a given string.
For example, SLICER(3, 7, 'PHOTOSYNTHESIS') would return 'OTOSY'.
The variable result is assigned a value using the statement:
result ← SLICER(4, 8, constellation)
Given the following variables:
constellation ← 'Cassiopeia'
spacecraft ← 'Voyager'
telescope ← 'Hubble'
destination ← 'Kepler-186f'
What is the value of result?
'iopei'
'siope'
'siop'
'iope'
89 exam-style questions on AQA GCSE Computer Science String handling operations in a programming language. Each one has a worked solution and a mark scheme showing where the marks go.