/**
 * The calculateTotalCost function takes a list of furniture prices and a discount percentage as inputs.
 * It calculates the total cost of the furniture after applying the discount and returns it.
 * You need to fill in the missing code to implement this function.
 * The continue statement and method: index() should be used to skip any furniture price below 1000 dollars.
 * Make sure to properly utilize these concepts to meet the requirements of this exercise.
 */
fun calculateTotalCost(furniturePriceList: List<Int>, discountPercentage: Int): Int {

    var totalCost = 0
    for (price in furniturePriceList) {
        if (price < 1000) {
            continue
        } else {
            totalCost += price
        }
    }

    totalCost -= (totalCost * discountPercentage) / 100  // Apply discount

    return totalCost
}
/**
 * The calculateTotalCost function takes a list of furniture prices and a discount percentage as inputs.
 * It calculates the total cost of the furniture after applying the discount and returns it.
 * You need to fill in the missing code to implement this function.
 * The continue statement and method: index() should be used to skip any furniture price below 1000 dollars.
 * Make sure to properly utilize these concepts to meet the requirements of this exercise.
 */
fun calculateTotalCost(furniturePriceList: List<Int>, discountPercentage: Int): Int {
/**
 * The calculateTotalCost function takes a list of furniture prices and a discount percentage as inputs.
 * It calculates the total cost of the furniture after applying the discount and returns it.
 * You need to fill in the missing code to implement this function.
 * The continue statement and method: index() should be used to skip any furniture price below 1000 dollars.
 * Make sure to properly utilize these concepts to meet the requirements of this exercise.
 */
fun calculateTotalCost(furniturePriceList: List<Int>, discountPercentage: Int): Int {

    var totalCost = 0
    for (price in furniturePriceList) {
        if (price < 1000) {
            continue
        } else {
            totalCost += price
        }
    }

    totalCost -= (totalCost * discountPercentage) / 100  // Apply discount

    return totalCost
}