String handling operations in a programming language

EasyMedium
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
Question 45
Easy

An algorithm is shown in the pseudo-code below:

1  probes ← ['Voyager', 'NewHorizons']
2  probe1 ← 'Kepler-186f'
3  probe2 ← 'Rosetta'
4  OUTPUT probe2
5  OUTPUT LEN(probes)
6  signal_code ← SUBSTRING(3, 5, probe1)
7  OUTPUT signal_code

Note: SUBSTRING(start, length, string) extracts a section of a string starting at index start (where the first character is at index 0) for the given character length.

State the output of line 7 from this algorithm.

[1]

String handling operations in a programming language Questions

  1. GCSE
  2. /Computer Science
  3. /String handling operations in a programming language