loading...

Discussion on: Python pro tips

Collapse
paddy3118 profile image
Paddy3118

You mention "Use shorter if statements". I get the sentiment but use a set literal rather than the list as it is better for such lookups, in general.

Collapse
epogrebnyak profile image
Evgeny Pogrebnyak

There is a view, often debated though, that the more if's you have is code, the less is the quality (eg flags in fucntions, avoidable branching, etc)

Some comments have been hidden by the post's author - find out more