This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: Faculty of Engineering, McMaster University Exceptions and Recursion Dr. Spencer Smith and Dr. William Farmer November 27, 2009 Smith: Exceptions and Recursion (slide 1) Exceptions and Recursion I Administrative Details I Exception Handling • Motivation • Exception Handling • Call Stack • Examples I Recursion • Motivation • Examples Smith: Exceptions and Recursion (slide 2) Administrative Details I Next marked lab involves completing existing code • Practise submission procedure this week • You may want to comment out code to get it to compile? I Extra help sessions this week • Wednesday, Nov 25, at 6:30 pm in ETB 118 • Thursday, Nov 26, at 6:30 in ETB 118 • Bring your questions! • Next extra help session, Dec 14, 10:30 am, room TBA I Lecture attendance grade is now posted • Will post again at the end of the term • If there is a problem, please register with your macid, not your student number I Please continue to attend your tutorials and lectures – we are covering some challenging material I Everything covered in lectures, labs and tutorials could be on the final exam Smith: Exceptions and Recursion (slide 3) Exceptions I We want our programs to be robust I In our marked and unmarked labs we have been ignoring potential problems • What if a user enters a value in the wrong range? • What if a user enters a double in the wrong format? ( 0.45ty instead of 0.4567 ?) • What if the file given by filename does not exist?...
View Full Document
- Spring '10
- Recursion, Subroutine, Call stack, Control flow, Dr. Spencer Smith