A random name generator.

A random name generator can be useful for creating dummy data for test purposes.

School club

⭐⭐

Make

Write a program to output a random name from one list of forenames and another list of surnames.

Success Criteria

Remember to add a comment before a subprogram, selection or iteration statement to explain its purpose.

Complete the subprogram called generate_name that:

  1. Assigns an array of forenames. You can use the names: Muhammad, Noah, Jack, Lily, Sophia, Olivia or some of your own.
  2. Assigns an array of surnames. You can use the names: Wang, Smith, Devi, Jones, Kim and Rodríguez or some of your own.
  3. It returns a random forename with a space and a random surname.

Complete the main program so that:

  1. It outputs a random name.

Typical inputs and outputs from the program would be:

Lily Rodríguez
Sophia Devi