/**
 * This exercise requires the psychologist to manipulate a string using loops to process a list of names.
 *
 * The psychologist is provided with a list of names as input and an ignore list of characters that should not be included in the final processed string. The task is to iterate over each name, remove any characters in the ignore list from each name, capitalize the first letter, and concatenate all processed names together into a single string.
 *
 * @param names A list of names to be processed.
 * @param ignoreList A string with characters to be ignored in the processing.
 * @return The processed string with concatenated names.
 *
 * Example:
 * processText(listOf("john", "mary"), "aeiou") returns "JHNMRY"
 */
fun processText(names: List<String>, ignoreList: String): String {

    var processedText = ""
    for (name in names) {
        var processedName = ""
        for (char in name) {
            if (char !in ignoreList) {
                processedName += char.toUpperCase()
            }
        }
        processedText += processedName
    }
    return processedText
}
/**
 * This exercise requires the psychologist to manipulate a string using loops to process a list of names.
 *
 * The psychologist is provided with a list of names as input and an ignore list of characters that should not be included in the final processed string. The task is to iterate over each name, remove any characters in the ignore list from each name, capitalize the first letter, and concatenate all processed names together into a single string.
 *
 * @param names A list of names to be processed.
 * @param ignoreList A string with characters to be ignored in the processing.
 * @return The processed string with concatenated names.
 *
 * Example:
 * processText(listOf("john", "mary"), "aeiou") returns "JHNMRY"
 */
fun processText(names: List<String>, ignoreList: String): String {
/**
 * This exercise requires the psychologist to manipulate a string using loops to process a list of names.
 *
 * The psychologist is provided with a list of names as input and an ignore list of characters that should not be included in the final processed string. The task is to iterate over each name, remove any characters in the ignore list from each name, capitalize the first letter, and concatenate all processed names together into a single string.
 *
 * @param names A list of names to be processed.
 * @param ignoreList A string with characters to be ignored in the processing.
 * @return The processed string with concatenated names.
 *
 * Example:
 * processText(listOf("john", "mary"), "aeiou") returns "JHNMRY"
 */
fun processText(names: List<String>, ignoreList: String): String {

    var processedText = ""
    for (name in names) {
        var processedName = ""
        for (char in name) {
            if (char !in ignoreList) {
                processedName += char.toUpperCase()
            }
        }
        processedText += processedName
    }
    return processedText
}