cs50 / problems

Checks for check50
134 stars 227 forks source link

CS50P week 7 "Working 9 to 5": staff version accepts invalid format #231

Open Richard-B-UK opened 7 months ago

Richard-B-UK commented 7 months ago

"In a file called working.py, implement a function called convert that expects a str in either of the 12-hour formats below...

9:00 AM to 5:00 PM
9 AM to 5 PM"

In test_working.py, I tested various invalid formats including "09 AM to 09 PM", intending to raise a ValueError; but this test caused the staff version to fail (ie, the staff version of working.py accepts this format).