fun main(args: Array<String>){
    val lIn = readLine()!!.split(" ").map(String::toInt)
    val n = lIn[0]
    val a = lIn[1]
    val b = lIn[2]
    val subMax = listOf(a, b).min()
    val subMin = listOf(0, (a + b) - n).max()
    println("$subMax $subMin")
}