comparison of “multi- `endswith`” in Python, four ways
Way too often, I want to know whether a filename string “ends with” anything in a list of various file extensions. In a pinch, I could use an if statement with multiple conditions, like this:… Read More »comparison of “multi- `endswith`” in Python, four ways