EAFP vs LBYL
Python favors EAFP (Easier to Ask Forgiveness than Permission): try the operation and handle failure with exceptions. LBYL (Look Before You Leap) checks conditions first. Both are valid; EAFP is idiomatic when the happy path is common and failures are exceptional.