+ 1
In C# /0 is infinite or error? I have infinite but another guy say me that is an error
2 ответов
+ 2
It'll throw an exception
https://docs.microsoft.com/en-us/dotnet/api/system.dividebyzeroexception?view=netframework-4.7.2
+ 1
Ok. I read this.
"Dividing a floating-point value by zero doesn't throw an exception; it results in positive infinity, negative infinity, or not a number (NaN), according to the rules of IEEE 754 arithmetic. "
I have a float var for these i have infinite
In Google not explain if the result is indetermination or infinite.
Thank you