为什么上面那个另设height运算后结果为0.000000,下面那个就可以得出准确的数值

img

img

height是想要double或float类型吧
另外:inch/12应该改成inch/12.0,因为inch是int类型,int/int结果仍为int