Roman Suzi
1 min readAug 31, 2019

--

I totally agree moving data around with the help of booleans can be not safe without proper discipline. I’d added one more case here. In some situations the choice is not binary. In addition to true/false, there may be for example missing value or some other values added later to what was first modeled as a boolean. So starting with integer enum is probably a safer choice in many situations.

That said, one correction: Python is strongly, dynamically typed language.

--

--

Responses (1)