/**
 * This function removes an element from a list at the specified index.
 *
 * @param lst The list from which the element should be removed
 * @param index The index of the element to be removed
 * @return The updated list with the element removed
 */
fun removeElement(lst: MutableList<Any>, index: Int): List<Any> {

    // Check if index is within the valid range
    if (index >= 0 && index < lst.size) {
        lst.removeAt(index)
    }
    return lst
}
/**
 * This function removes an element from a list at the specified index.
 *
 * @param lst The list from which the element should be removed
 * @param index The index of the element to be removed
 * @return The updated list with the element removed
 */
fun removeElement(lst: MutableList<Any>, index: Int): List<Any> {
/**
 * This function removes an element from a list at the specified index.
 *
 * @param lst The list from which the element should be removed
 * @param index The index of the element to be removed
 * @return The updated list with the element removed
 */
fun removeElement(lst: MutableList<Any>, index: Int): List<Any> {

    // Check if index is within the valid range
    if (index >= 0 && index < lst.size) {
        lst.removeAt(index)
    }
    return lst
}