/**
 * Given a list of numbers, shift the elements to the left and right based on the given leftShift and rightShift.
 *
 * @param numbers A list of integers.
 * @param leftShift An integer specifying the number of positions to shift the elements to the left.
 * @param rightShift An integer specifying the number of positions to shift the elements to the right.
 * @return A new list with the elements shifted to the left and right.
 */
fun createShiftedList(numbers: List<Int>, leftShift: Int, rightShift: Int): List<Int> {

    var shiftedList = numbers.subList(leftShift, numbers.size) + numbers.subList(0, leftShift) // Shift elements to the left
    shiftedList = shiftedList.subList(shiftedList.size - rightShift, shiftedList.size) + shiftedList.subList(0, shiftedList.size - rightShift) // Shift elements to the right
    return shiftedList
}

// Example Usage
/**
 * Given a list of numbers, shift the elements to the left and right based on the given leftShift and rightShift.
 *
 * @param numbers A list of integers.
 * @param leftShift An integer specifying the number of positions to shift the elements to the left.
 * @param rightShift An integer specifying the number of positions to shift the elements to the right.
 * @return A new list with the elements shifted to the left and right.
 */
fun createShiftedList(numbers: List<Int>, leftShift: Int, rightShift: Int): List<Int> {
/**
 * Given a list of numbers, shift the elements to the left and right based on the given leftShift and rightShift.
 *
 * @param numbers A list of integers.
 * @param leftShift An integer specifying the number of positions to shift the elements to the left.
 * @param rightShift An integer specifying the number of positions to shift the elements to the right.
 * @return A new list with the elements shifted to the left and right.
 */
fun createShiftedList(numbers: List<Int>, leftShift: Int, rightShift: Int): List<Int> {

    var shiftedList = numbers.subList(leftShift, numbers.size) + numbers.subList(0, leftShift) // Shift elements to the left
    shiftedList = shiftedList.subList(shiftedList.size - rightShift, shiftedList.size) + shiftedList.subList(0, shiftedList.size - rightShift) // Shift elements to the right
    return shiftedList
}

// Example Usage