The method used on page 160 for checking whether or not a float is infinite looks to have been replaced by float.IsInfinity(), at least in .NET version 5.0.300
Negating the result of IsInfinity() would fix the example of any errors
Good catch—thanks! You're right, that bit of code was never changed from the 3rd edition of the book, before IsFinite was deprecated. I'll make sure future printings and digital editions are updated.
The method used on page 160 for checking whether or not a float is infinite looks to have been replaced by
float.IsInfinity()
, at least in .NET version 5.0.300Negating the result of IsInfinity() would fix the example of any errors