ID EN
Math

isfinite

Python 3.11

Return True if x is neither an infinity nor a NaN, and False otherwise. (Note that 0.0 is considered finite.)

Syntax

PYTHON
math.isfinite(x)