/**
 * This exercise is designed to test your understanding of accessing tuple elements and using an else statement in Python.
 * You will be given a nested tuple containing several inner tuples. Each inner tuple consists of an integer and a string.
 * Your task is to iterate through the outer tuple and print the integer elements from the inner tuples using the following conditions:
 * - If the element is divisible by 3, print 'Fizz'
 * - If the element is divisible by 5, print 'Buzz'
 * - If the element is divisible by both 3 and 5, print 'FizzBuzz'
 * - If none of the above conditions are met, print the element itself.
 * Keep in mind that the nested tuple can have any number of inner tuples.
 */
fun accessNestedTuple(nestedTuple: List<Pair<Int, String>>) {

    for (innerTuple in nestedTuple) {
        when {
            innerTuple.first % 3 == 0 && innerTuple.first % 5 == 0 -> println("FizzBuzz")
            innerTuple.first % 3 == 0 -> println("Fizz")
            innerTuple.first % 5 == 0 -> println("Buzz")
            else -> println(innerTuple.first)
        }
    }
}
/**
 * This exercise is designed to test your understanding of accessing tuple elements and using an else statement in Python.
 * You will be given a nested tuple containing several inner tuples. Each inner tuple consists of an integer and a string.
 * Your task is to iterate through the outer tuple and print the integer elements from the inner tuples using the following conditions:
 * - If the element is divisible by 3, print 'Fizz'
 * - If the element is divisible by 5, print 'Buzz'
 * - If the element is divisible by both 3 and 5, print 'FizzBuzz'
 * - If none of the above conditions are met, print the element itself.
 * Keep in mind that the nested tuple can have any number of inner tuples.
 */
fun accessNestedTuple(nestedTuple: List<Pair<Int, String>>) {
/**
 * This exercise is designed to test your understanding of accessing tuple elements and using an else statement in Python.
 * You will be given a nested tuple containing several inner tuples. Each inner tuple consists of an integer and a string.
 * Your task is to iterate through the outer tuple and print the integer elements from the inner tuples using the following conditions:
 * - If the element is divisible by 3, print 'Fizz'
 * - If the element is divisible by 5, print 'Buzz'
 * - If the element is divisible by both 3 and 5, print 'FizzBuzz'
 * - If none of the above conditions are met, print the element itself.
 * Keep in mind that the nested tuple can have any number of inner tuples.
 */
fun accessNestedTuple(nestedTuple: List<Pair<Int, String>>) {

    for (innerTuple in nestedTuple) {
        when {
            innerTuple.first % 3 == 0 && innerTuple.first % 5 == 0 -> println("FizzBuzz")
            innerTuple.first % 3 == 0 -> println("Fizz")
            innerTuple.first % 5 == 0 -> println("Buzz")
            else -> println(innerTuple.first)
        }
    }
}