static void Main(string[] args) { try { Argument arguments = new Argument(args); if (arguments.Validate()) Work(arguments); } catch (Exception ex) { System.Console.WriteLine(ex.Message); } }
static void Main(string[] args) { try { Argument arguments = new Argument(args); if (arguments.Validate()) { Work(arguments); } } catch (Exception ex) { System.Console.WriteLine(ex.Message); } }
static int Main(string[] args) { bool completedSuccessfully = false; try { Argument arguments = new Argument(args); if (arguments.Validate()) completedSuccessfully = Work(arguments); } catch (Exception ex) { Console.WriteLine(ex.Message); } return completedSuccessfully ? 0 : 1; }
static int Main(string[] args) { bool completedSuccessfully = false; try { Argument arguments = new Argument(args); if (arguments.Validate()) { completedSuccessfully = Work(arguments); } } catch (Exception ex) { Console.WriteLine(ex.Message); } return(completedSuccessfully ? 0 : 1); }