/**
 * This function takes a zoo list and an index number as arguments and returns the name of the animal at the specified index
 * in the zoo list using the division assignment operator and negative indexing.
 *
 * @param zoo A list of animal names in the zoo.
 * @param index An integer representing the index of the animal in the zoo list.
 * @return The name of the animal at the specified index in the zoo list.
 *
 * Example:
 * findZooAnimals(listOf("lion", "tiger", "bear", "elephant"), -2) // Output: "bear"
 */
fun findZooAnimals(zoo: List<String>, index: Int): String {

    // Divide the list length into halves using floor division
    val halfLength = zoo.size / 2

    // Get the actual index using negative indexing and assignment operator
    val actualIndex = index / halfLength

    // Return the animal at the actual index in the zoo list
    return zoo[actualIndex]
}
/**
 * This function takes a zoo list and an index number as arguments and returns the name of the animal at the specified index
 * in the zoo list using the division assignment operator and negative indexing.
 *
 * @param zoo A list of animal names in the zoo.
 * @param index An integer representing the index of the animal in the zoo list.
 * @return The name of the animal at the specified index in the zoo list.
 *
 * Example:
 * findZooAnimals(listOf("lion", "tiger", "bear", "elephant"), -2) // Output: "bear"
 */
fun findZooAnimals(zoo: List<String>, index: Int): String {
/**
 * This function takes a zoo list and an index number as arguments and returns the name of the animal at the specified index
 * in the zoo list using the division assignment operator and negative indexing.
 *
 * @param zoo A list of animal names in the zoo.
 * @param index An integer representing the index of the animal in the zoo list.
 * @return The name of the animal at the specified index in the zoo list.
 *
 * Example:
 * findZooAnimals(listOf("lion", "tiger", "bear", "elephant"), -2) // Output: "bear"
 */
fun findZooAnimals(zoo: List<String>, index: Int): String {

    // Divide the list length into halves using floor division
    val halfLength = zoo.size / 2

    // Get the actual index using negative indexing and assignment operator
    val actualIndex = index / halfLength

    // Return the animal at the actual index in the zoo list
    return zoo[actualIndex]
}