Catching Generic Exceptions
Mon 10 August 2026
try:
risky_operation()
except Exception as e:
print("Error:", e)
Error: name 'risky_operation' is not defined
Score: 10
Category: chapter6_exception_handling
try:
risky_operation()
except Exception as e:
print("Error:", e)
Error: name 'risky_operation' is not defined
Score: 10
Category: chapter6_exception_handling