/**
 * This function removes elements from a list using slicing.
 *
 * @param someList A list containing elements.
 * @param start The starting index of the slice.
 * @param end The ending index of the slice.
 * @return The original list with elements removed within the specified range.
 *
 * Examples:
 * removeElements(listOf(1, 2, 3, 4, 5), 1, 3) // [1, 5]
 * removeElements(listOf('a', 'b', 'c', 'd', 'e'), 0, -1) // ['e']
 */
fun removeElements(someList: List<Any>, start: Int, end: Int): List<Any> {

    val modifiedList = someList.subList(0, start) + someList.subList(end + 1, someList.size)
    return modifiedList
}
/**
 * This function removes elements from a list using slicing.
 *
 * @param someList A list containing elements.
 * @param start The starting index of the slice.
 * @param end The ending index of the slice.
 * @return The original list with elements removed within the specified range.
 *
 * Examples:
 * removeElements(listOf(1, 2, 3, 4, 5), 1, 3) // [1, 5]
 * removeElements(listOf('a', 'b', 'c', 'd', 'e'), 0, -1) // ['e']
 */
fun removeElements(someList: List<Any>, start: Int, end: Int): List<Any> {
/**
 * This function removes elements from a list using slicing.
 *
 * @param someList A list containing elements.
 * @param start The starting index of the slice.
 * @param end The ending index of the slice.
 * @return The original list with elements removed within the specified range.
 *
 * Examples:
 * removeElements(listOf(1, 2, 3, 4, 5), 1, 3) // [1, 5]
 * removeElements(listOf('a', 'b', 'c', 'd', 'e'), 0, -1) // ['e']
 */
fun removeElements(someList: List<Any>, start: Int, end: Int): List<Any> {

    val modifiedList = someList.subList(0, start) + someList.subList(end + 1, someList.size)
    return modifiedList
}