/**
 * This function takes a chef's name and a list of menu items and creates a menu.
 * Each item in the menu is represented as a Pair containing the dish name and its price.
 *
 * @param chefName The name of the chef.
 * @param menuItems A list of Pairs representing menu items.
 * @return A list of formatted strings representing the menu.
 *
 * Example:
 * createMenu("Chef Gordon", listOf("Steak" to 25.99, "Salmon" to 21.99, "Cheesecake" to 8.99))
 *
 * Output:
 * ["Chef Gordon's Menu:", "1. Steak - $25.99", "2. Salmon - $21.99", "3. Cheesecake - $8.99"]
 */
fun createMenu(chefName: String, menuItems: List<Pair<String, Double>>): List<String> {

    val menu = mutableListOf<String>()
    
    menu.add("$chefName's Menu:")
    
    menuItems.forEachIndexed { index, (dish, price) ->
        menu.add("${index + 1}. $dish - $$price")
    }
    
    return menu
}
/**
 * This function takes a chef's name and a list of menu items and creates a menu.
 * Each item in the menu is represented as a Pair containing the dish name and its price.
 *
 * @param chefName The name of the chef.
 * @param menuItems A list of Pairs representing menu items.
 * @return A list of formatted strings representing the menu.
 *
 * Example:
 * createMenu("Chef Gordon", listOf("Steak" to 25.99, "Salmon" to 21.99, "Cheesecake" to 8.99))
 *
 * Output:
 * ["Chef Gordon's Menu:", "1. Steak - $25.99", "2. Salmon - $21.99", "3. Cheesecake - $8.99"]
 */
fun createMenu(chefName: String, menuItems: List<Pair<String, Double>>): List<String> {
/**
 * This function takes a chef's name and a list of menu items and creates a menu.
 * Each item in the menu is represented as a Pair containing the dish name and its price.
 *
 * @param chefName The name of the chef.
 * @param menuItems A list of Pairs representing menu items.
 * @return A list of formatted strings representing the menu.
 *
 * Example:
 * createMenu("Chef Gordon", listOf("Steak" to 25.99, "Salmon" to 21.99, "Cheesecake" to 8.99))
 *
 * Output:
 * ["Chef Gordon's Menu:", "1. Steak - $25.99", "2. Salmon - $21.99", "3. Cheesecake - $8.99"]
 */
fun createMenu(chefName: String, menuItems: List<Pair<String, Double>>): List<String> {

    val menu = mutableListOf<String>()
    
    menu.add("$chefName's Menu:")
    
    menuItems.forEachIndexed { index, (dish, price) ->
        menu.add("${index + 1}. $dish - $$price")
    }
    
    return menu
}