Software engineering and personal development

Tag: multiple

How to Quickly Check Whether at Least One Condition is Met in Python

In many cases, we may have multiple conditions that we want to check, and going through each one of them can be a clutter.

First and foremost, we should keep in mind that we write code for other humans to read it. These are our colleagues that work with us, or people who use our open source projects.

As such, checking whether at least one condition is met can be done using a very quick way by using the method any().

Continue reading

© 2024 Fatos Morina

Theme by Anders NorenUp ↑