/**
 * Given the total number of elements and an index, return the corresponding negative index.
 *
 * @param numElements The total number of elements in the list.
 * @param index The index of an element.
 * @return The negative index.
 */
fun getNegativeIndex(numElements: Int, index: Int): Int {

    val negativeIndex = index - numElements
    return negativeIndex
}
/**
 * Given the total number of elements and an index, return the corresponding negative index.
 *
 * @param numElements The total number of elements in the list.
 * @param index The index of an element.
 * @return The negative index.
 */
fun getNegativeIndex(numElements: Int, index: Int): Int {
/**
 * Given the total number of elements and an index, return the corresponding negative index.
 *
 * @param numElements The total number of elements in the list.
 * @param index The index of an element.
 * @return The negative index.
 */
fun getNegativeIndex(numElements: Int, index: Int): Int {

    val negativeIndex = index - numElements
    return negativeIndex
}