/**
 * This function takes in two sets, 'names' and 'ages', and creates a list of patient information.
 *
 * @param names Set of patient names.
 * @param ages Set of patient ages.
 * @return A list containing the names and ages of the patients.
 */
fun createListOfPatients(names: Set<String>, ages: Set<Int>): List<Map<String, Any>> {

    val patientInformation = mutableListOf<Map<String, Any>>()

    names.zip(ages).forEach { (name, age) ->
        val patientInfo = mutableMapOf<String, Any>()
        patientInfo["name"] = name
        patientInfo["age"] = age
        patientInformation.add(patientInfo)
    }

    return patientInformation
}
/**
 * This function takes in two sets, 'names' and 'ages', and creates a list of patient information.
 *
 * @param names Set of patient names.
 * @param ages Set of patient ages.
 * @return A list containing the names and ages of the patients.
 */
fun createListOfPatients(names: Set<String>, ages: Set<Int>): List<Map<String, Any>> {
/**
 * This function takes in two sets, 'names' and 'ages', and creates a list of patient information.
 *
 * @param names Set of patient names.
 * @param ages Set of patient ages.
 * @return A list containing the names and ages of the patients.
 */
fun createListOfPatients(names: Set<String>, ages: Set<Int>): List<Map<String, Any>> {

    val patientInformation = mutableListOf<Map<String, Any>>()

    names.zip(ages).forEach { (name, age) ->
        val patientInfo = mutableMapOf<String, Any>()
        patientInfo["name"] = name
        patientInfo["age"] = age
        patientInformation.add(patientInfo)
    }

    return patientInformation
}