mirror of
https://hub.njuu.cf/TheAlgorithms/C-Plus-Plus.git
synced 2023-10-11 13:05:55 +08:00
Update sqrt_double.cpp
This commit is contained in:
parent
f27f3fcbf0
commit
a4d3475ed5
@ -12,6 +12,7 @@ double Sqrt(double x) {
|
||||
between 1e-7 and 1e-12.
|
||||
double epsilon = 1e-12;
|
||||
*/
|
||||
double epsilon = 1e-12;
|
||||
while ( l <= r ) {
|
||||
double mid = (l + r) / 2;
|
||||
if ( mid * mid > x ) {
|
||||
|
Loading…
Reference in New Issue
Block a user