Answer to Question number-1

Values of type double are more precise, making roundoff error less of a problem. (Unfortunately, that does not eliminate the problem of roundoff error.)