fun main (args:Array<String>){
    val(max, waterB, waterC) = readLine()!!.split(" ").map(String::toInt)
    val ans = waterC - (max - waterB)
    if(ans < 0) {
        print(0)
        return
    }
    print(ans)
}