/**
 * This exercise will test your understanding of tuples and nested loops in Kotlin.
 *
 * You are given a list of athletes, where each athlete's information is represented as a triple of three elements:
 * - The athlete's name (string)
 * - The athlete's country (string)
 * - The athlete's medals (list of strings)
 *
 * Your task is to create a function that takes an athlete as input, and prints a message displaying the athlete's name,
 * country, and the number of medals they have won, as well as the name of each medal.
 *
 * Example:
 * val athlete = Triple("Michael Phelps", "USA", listOf("gold", "gold", "silver", "gold", "bronze"))
 * athleteData(athlete)
 *
 * Expected output:
 * Michael Phelps from USA has won 5 medals:
 * - gold
 * - gold
 * - silver
 * - gold
 * - bronze
 */
fun athleteData(athlete: Triple<String, String, List<String>>) {

    val (name, country, medals) = athlete
    val medalsCount = medals.size

    println("$name from $country has won $medalsCount medals:")

    for (medal in medals) {
        println("- $medal")
    }
}
/**
 * This exercise will test your understanding of tuples and nested loops in Kotlin.
 *
 * You are given a list of athletes, where each athlete's information is represented as a triple of three elements:
 * - The athlete's name (string)
 * - The athlete's country (string)
 * - The athlete's medals (list of strings)
 *
 * Your task is to create a function that takes an athlete as input, and prints a message displaying the athlete's name,
 * country, and the number of medals they have won, as well as the name of each medal.
 *
 * Example:
 * val athlete = Triple("Michael Phelps", "USA", listOf("gold", "gold", "silver", "gold", "bronze"))
 * athleteData(athlete)
 *
 * Expected output:
 * Michael Phelps from USA has won 5 medals:
 * - gold
 * - gold
 * - silver
 * - gold
 * - bronze
 */
fun athleteData(athlete: Triple<String, String, List<String>>) {
/**
 * This exercise will test your understanding of tuples and nested loops in Kotlin.
 *
 * You are given a list of athletes, where each athlete's information is represented as a triple of three elements:
 * - The athlete's name (string)
 * - The athlete's country (string)
 * - The athlete's medals (list of strings)
 *
 * Your task is to create a function that takes an athlete as input, and prints a message displaying the athlete's name,
 * country, and the number of medals they have won, as well as the name of each medal.
 *
 * Example:
 * val athlete = Triple("Michael Phelps", "USA", listOf("gold", "gold", "silver", "gold", "bronze"))
 * athleteData(athlete)
 *
 * Expected output:
 * Michael Phelps from USA has won 5 medals:
 * - gold
 * - gold
 * - silver
 * - gold
 * - bronze
 */
fun athleteData(athlete: Triple<String, String, List<String>>) {

    val (name, country, medals) = athlete
    val medalsCount = medals.size

    println("$name from $country has won $medalsCount medals:")

    for (medal in medals) {
        println("- $medal")
    }
}