• + 0 comments

    Kotlin solution:

    val tallestHeight = height.maxOrNull() ?: 0 val result = tallestHeight - k

    if (result < 0){
        return 0
    } else {
        return result
    }