/**
 * This function takes a list of furniture items and a list of replacement items.
 * It replaces the current furniture item in the list with a random replacement item
 * if the item is not a preferred furniture item for an interior designer.
 * It then returns the modified list.
 */
fun rearrangeFurniture(furnitureList: MutableList<String>, replaceList: List<String>): MutableList<String> {

    val preferredFurniture = listOf("chair", "sofa", "table", "lamp")
    val modifiedList = furnitureList.toMutableList()
    for (index in modifiedList.indices) {
        if (modifiedList[index] !in preferredFurniture) {
            modifiedList[index] = replaceList.random()
        }
    }
    return modifiedList
}
/**
 * This function takes a list of furniture items and a list of replacement items.
 * It replaces the current furniture item in the list with a random replacement item
 * if the item is not a preferred furniture item for an interior designer.
 * It then returns the modified list.
 */
fun rearrangeFurniture(furnitureList: MutableList<String>, replaceList: List<String>): MutableList<String> {
/**
 * This function takes a list of furniture items and a list of replacement items.
 * It replaces the current furniture item in the list with a random replacement item
 * if the item is not a preferred furniture item for an interior designer.
 * It then returns the modified list.
 */
fun rearrangeFurniture(furnitureList: MutableList<String>, replaceList: List<String>): MutableList<String> {

    val preferredFurniture = listOf("chair", "sofa", "table", "lamp")
    val modifiedList = furnitureList.toMutableList()
    for (index in modifiedList.indices) {
        if (modifiedList[index] !in preferredFurniture) {
            modifiedList[index] = replaceList.random()
        }
    }
    return modifiedList
}