/**
 * You are a chef and you have a list of ingredients to chop. Each ingredient is represented 
 * as a Pair containing the name of the ingredient and a boolean value indicating whether it 
 * needs to be chopped or not. Your task is to chop all the ingredients that require chopping 
 * and return a new list of ingredients with the updated values.
 *
 * @param ingredients List of ingredients to chop
 * @return New list of ingredients with the updated values
 */
fun chopIngredients(ingredients: List<Pair<String, Boolean>>): List<Pair<String, Boolean>> {

    val choppedIngredients = mutableListOf<Pair<String, Boolean>>()

    for ((ingredient, chopStatus) in ingredients) {
        if (chopStatus) {
            choppedIngredients.add(Pair(ingredient, true))
        } else {
            choppedIngredients.add(Pair(ingredient, false))
        }
    }

    return choppedIngredients
}
/**
 * You are a chef and you have a list of ingredients to chop. Each ingredient is represented 
 * as a Pair containing the name of the ingredient and a boolean value indicating whether it 
 * needs to be chopped or not. Your task is to chop all the ingredients that require chopping 
 * and return a new list of ingredients with the updated values.
 *
 * @param ingredients List of ingredients to chop
 * @return New list of ingredients with the updated values
 */
fun chopIngredients(ingredients: List<Pair<String, Boolean>>): List<Pair<String, Boolean>> {
/**
 * You are a chef and you have a list of ingredients to chop. Each ingredient is represented 
 * as a Pair containing the name of the ingredient and a boolean value indicating whether it 
 * needs to be chopped or not. Your task is to chop all the ingredients that require chopping 
 * and return a new list of ingredients with the updated values.
 *
 * @param ingredients List of ingredients to chop
 * @return New list of ingredients with the updated values
 */
fun chopIngredients(ingredients: List<Pair<String, Boolean>>): List<Pair<String, Boolean>> {

    val choppedIngredients = mutableListOf<Pair<String, Boolean>>()

    for ((ingredient, chopStatus) in ingredients) {
        if (chopStatus) {
            choppedIngredients.add(Pair(ingredient, true))
        } else {
            choppedIngredients.add(Pair(ingredient, false))
        }
    }

    return choppedIngredients
}