/**
 * Given a nested tuple of scores, return the highest score.
 *
 * The input 'scores' is a nested tuple which contains tuples of student scores for different subjects. The format of the tuple is as follows:
 * ((subject1, score1), (subject2, score2), ...)
 *
 * @param scores A nested tuple of student scores. Each item is a tuple containing the subject name and the corresponding score.
 * @return The highest score among all subjects.
 */
fun getHighestScore(scores: List<Pair<String, Int>>): Int {

    var highestScore = Int.MIN_VALUE  // Initialize highestScore with negative infinite value

    for ((_, score) in scores) {
        highestScore = maxOf(highestScore, score)
    }

    return highestScore
}
/**
 * Given a nested tuple of scores, return the highest score.
 *
 * The input 'scores' is a nested tuple which contains tuples of student scores for different subjects. The format of the tuple is as follows:
 * ((subject1, score1), (subject2, score2), ...)
 *
 * @param scores A nested tuple of student scores. Each item is a tuple containing the subject name and the corresponding score.
 * @return The highest score among all subjects.
 */
fun getHighestScore(scores: List<Pair<String, Int>>): Int {
/**
 * Given a nested tuple of scores, return the highest score.
 *
 * The input 'scores' is a nested tuple which contains tuples of student scores for different subjects. The format of the tuple is as follows:
 * ((subject1, score1), (subject2, score2), ...)
 *
 * @param scores A nested tuple of student scores. Each item is a tuple containing the subject name and the corresponding score.
 * @return The highest score among all subjects.
 */
fun getHighestScore(scores: List<Pair<String, Int>>): Int {

    var highestScore = Int.MIN_VALUE  // Initialize highestScore with negative infinite value

    for ((_, score) in scores) {
        highestScore = maxOf(highestScore, score)
    }

    return highestScore
}