Logic of triangle inequality as python conditionals?
<p><em>[community edit: original title was "python conditionals", OP is asking what is wrong with code below]</em></p>

<p>I made a function that's supposed to determine if three sides can theoretically form a triangle. It works fine in my opinion , but when i input the code in pyschools.com website, it tells that in some test cases it doesn't work (unfortunately it doesn't show me the cases it didn't work). Is something missing from my code, so in some special cases my logic breas down? Thank you very much for your help.
Here's the function:</p>

<pre><code>import math
def isTriangle(x, y, z):
    if x &gt; 0 and y &gt; 0 and z &gt; 0:
        if x &gt; y and x &gt; z:
            c = x
        elif y &gt; x and y &gt; z:
            c = y
        else:
            c = z
        if c == math.sqrt(x**2 + y**2):
            return True
        else:
            return False
    else:
        return False
</code></pre>
