using System; using System.Collections.Generic; using System.Text; namespace 异常捕获 { class Program { staticvoid Main(string[] args) { int a =1; int b =0; try { a = a / b; } catch (System.DivideByZeroException e) { Console.WriteLine(e.Message); } } } }