def previous_workday(dt):
dt -= timedelta(days=<NUM_LIT:1>)<EOL>while dt.weekday() > <NUM_LIT:4>:<EOL><INDENT>dt -= timedelta(days=<NUM_LIT:1>)<EOL><DEDENT>return dt<EOL>
returns previous weekday used for observances