/**
 * This exercise focuses on the intersection of the "is not" operator and the creation of a tuple.
 * Given a list of tuples containing the name of a historical figure and a description,
 * write a function that filters out the tuples where the name of the figure is not equal to "Abraham Lincoln",
 * and returns a new tuple with only the descriptions.
 *
 * Assume the input list is of the following format:
 * [("Historical Figure 1", "Description 1"), ("Abraham Lincoln", "Description 2"), ...]
 *
 * Complete the code to solve the exercise.
 */
fun intersectionOfIsNotOperatorAndCreatingATuple(historian: List<Pair<String, String>>): List<String> {

    val filteredDescriptions = mutableListOf<String>()  // Initialize an empty list for storing the filtered descriptions

    // Loop through each tuple in the input list
    for ((figure, description) in historian) {
        if (figure != "Abraham Lincoln") {  // Check if the name of the historical figure is not equal to "Abraham Lincoln"
            filteredDescriptions.add(description)  // Add the description to the filteredDescriptions list
        }
    }

    return filteredDescriptions
}
/**
 * This exercise focuses on the intersection of the "is not" operator and the creation of a tuple.
 * Given a list of tuples containing the name of a historical figure and a description,
 * write a function that filters out the tuples where the name of the figure is not equal to "Abraham Lincoln",
 * and returns a new tuple with only the descriptions.
 *
 * Assume the input list is of the following format:
 * [("Historical Figure 1", "Description 1"), ("Abraham Lincoln", "Description 2"), ...]
 *
 * Complete the code to solve the exercise.
 */
fun intersectionOfIsNotOperatorAndCreatingATuple(historian: List<Pair<String, String>>): List<String> {
/**
 * This exercise focuses on the intersection of the "is not" operator and the creation of a tuple.
 * Given a list of tuples containing the name of a historical figure and a description,
 * write a function that filters out the tuples where the name of the figure is not equal to "Abraham Lincoln",
 * and returns a new tuple with only the descriptions.
 *
 * Assume the input list is of the following format:
 * [("Historical Figure 1", "Description 1"), ("Abraham Lincoln", "Description 2"), ...]
 *
 * Complete the code to solve the exercise.
 */
fun intersectionOfIsNotOperatorAndCreatingATuple(historian: List<Pair<String, String>>): List<String> {

    val filteredDescriptions = mutableListOf<String>()  // Initialize an empty list for storing the filtered descriptions

    // Loop through each tuple in the input list
    for ((figure, description) in historian) {
        if (figure != "Abraham Lincoln") {  // Check if the name of the historical figure is not equal to "Abraham Lincoln"
            filteredDescriptions.add(description)  // Add the description to the filteredDescriptions list
        }
    }

    return filteredDescriptions
}