异常
异常
try {
val result = 5 / 0
println("---->")
} catch {
case e: Exception => e.printStackTrace()
case _ => println("other Exception!")
} finally {
println("end")
}
java.lang.ArithmeticException: / by zero
at base.file_Out_In$.main(file_Out_In.scala:17)
at base.file_Out_In.main(file_Out_In.scala)
end