Never mind about the second problem. I fixed it by declaring it a 'long double'.