added usage of fromIntegral