Lesson 8: Error Handling (Try-Except)
Objective: Prevent crashes from user errors.
-
try,except,finally.
Code Example:
try: num = int(input("Enter a number: ")) except ValueError: print("Invalid input!")
Exercise:
-
Modify a calculator to handle non-numeric inputs.

