Variable below zero but if statement doesn't grab?

TheDGuy via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sun Dec 27 08:52:39 PST 2015


On Sunday, 27 December 2015 at 16:48:44 UTC, SimonN wrote:
> On Sunday, 27 December 2015 at 16:41:10 UTC, TheDGuy wrote:
>> It looks like the debugger is not working correctly because i 
>> changed the code to this:
>> [...]
>> and the same problem appears.
>
> I can't watch youtube here. What numbers does your input 
> generate? Which 'if' doesn't fire? What results would you like 
> instead?
>
> -- Simon

I don't understand why my program goes into the if statement if 
the debugger shows, that the variable "discriminant" is below 
zero even though:

"if(discriminant > 0)"?


More information about the Digitalmars-d-learn mailing list