If it is, then the squares of the short side and the medium side add up to the square of the longest side.
Let's check it out:
Square of the short side = 17² = 289
Square of the medium side = 24² = 576
These two squares add up to (289 + 576) = 865
Square of the longest side = 40² = 1,600
865 is not equal to 1,600.
So these three numbers do <em>not </em>make a right triangle.