/**
 * Given two lists, modify list1 by removing elements that are present in list2.
 *
 * @param list1 The first list.
 * @param list2 The second list.
 * @return The modified list1.
 */
fun modifyList(list1: MutableList<Any>, list2: List<Any>): MutableList<Any> {

    for (element2 in list2) {
        if (element2 in list1) {
            list1.remove(element2)
        }
    }
    return list1
}
/**
 * Given two lists, modify list1 by removing elements that are present in list2.
 *
 * @param list1 The first list.
 * @param list2 The second list.
 * @return The modified list1.
 */
fun modifyList(list1: MutableList<Any>, list2: List<Any>): MutableList<Any> {
/**
 * Given two lists, modify list1 by removing elements that are present in list2.
 *
 * @param list1 The first list.
 * @param list2 The second list.
 * @return The modified list1.
 */
fun modifyList(list1: MutableList<Any>, list2: List<Any>): MutableList<Any> {

    for (element2 in list2) {
        if (element2 in list1) {
            list1.remove(element2)
        }
    }
    return list1
}