Inspectopedia
 
2024.3

Too complex chained comparisons

Info
New
Last modified: 03 December 2024

Reports chained comparisons that can be simplified.

Example:

The IDE offers to simplify if x >= xmin and x <= xmax. When the quick-fix is applied, the code changes to: