Skip to content
MathsGenie logo
Open app

Course home

  1. IGCSE
  2. Computer Science Edexcel
  3. Question bank

Develop code

EasyMediumHard
123456789101112131415161718192021222324252627
Question 2

Each software project uses a list of programming languages.

An incomplete algorithm written in pseudocode is shown below.

The algorithm must:

  1. Print each language in the list to the display on a new line.
  2. Count the total number of languages in the list.
  3. Create a message as a single string (e.g. "The project uses 5 languages").
  4. Print this final message to the display.

Complete the pseudocode algorithm below.

SET total TO 0
SET languages TO ["Python", "Java", "C++", "JavaScript", "Rust"]
FOR EACH lang FROM languages DO

END FOREACH
[4]

Develop code Questions

  1. IGCSE
  2. /Computer Science
  3. /Develop code