/**
 * Given a list of coordinates in (longitude, latitude, depth) format,
 * find the minimum and maximum depth values among all the coordinates.
 *
 * @param coordinates A list of coordinates in (longitude, latitude, depth) format
 * @return A Pair containing the minimum and maximum depth values
 */
fun findMinMaxDepth(coordinates: List<Triple<Double, Double, Double>>): Pair<Double, Double> {

    // Initialize the minimum and maximum depth values
    var minDepth = Double.POSITIVE_INFINITY
    var maxDepth = Double.NEGATIVE_INFINITY

    // Iterate through each coordinate in the list
    for (coordinate in coordinates) {
        val (_, _, depth) = coordinate

        // Check if the current depth is smaller than the minimum depth
        if (depth < minDepth) {
            minDepth = depth
        }

        // Check if the current depth is greater than the maximum depth
        if (depth > maxDepth) {
            maxDepth = depth
        }
    }

    return Pair(minDepth, maxDepth)
}
/**
 * Given a list of coordinates in (longitude, latitude, depth) format,
 * find the minimum and maximum depth values among all the coordinates.
 *
 * @param coordinates A list of coordinates in (longitude, latitude, depth) format
 * @return A Pair containing the minimum and maximum depth values
 */
fun findMinMaxDepth(coordinates: List<Triple<Double, Double, Double>>): Pair<Double, Double> {
/**
 * Given a list of coordinates in (longitude, latitude, depth) format,
 * find the minimum and maximum depth values among all the coordinates.
 *
 * @param coordinates A list of coordinates in (longitude, latitude, depth) format
 * @return A Pair containing the minimum and maximum depth values
 */
fun findMinMaxDepth(coordinates: List<Triple<Double, Double, Double>>): Pair<Double, Double> {

    // Initialize the minimum and maximum depth values
    var minDepth = Double.POSITIVE_INFINITY
    var maxDepth = Double.NEGATIVE_INFINITY

    // Iterate through each coordinate in the list
    for (coordinate in coordinates) {
        val (_, _, depth) = coordinate

        // Check if the current depth is smaller than the minimum depth
        if (depth < minDepth) {
            minDepth = depth
        }

        // Check if the current depth is greater than the maximum depth
        if (depth > maxDepth) {
            maxDepth = depth
        }
    }

    return Pair(minDepth, maxDepth)
}