Thanks for testing this.
The second one, with [0], is correct.
The function isfinite(x) returns True, i.e. 1, for finite numbers and False for Infinity and NaN.
The second one, with [0], is correct.
The function isfinite(x) returns True, i.e. 1, for finite numbers and False for Infinity and NaN.