F
Frankdot
Guest
Hello,
I have this code i would like to modify. It return the closest number from my variable fibo1.
But it return any number positive or not.
I would like to know if any one could tell me how to modify it to get the closest positive number.
Thank you
double minDistance = list.Min(no => Math.Abs(fibo1- no));
double closest = list.First(no => Math.Abs(fibo1- no) == minDistance);
Continue reading...
I have this code i would like to modify. It return the closest number from my variable fibo1.
But it return any number positive or not.
I would like to know if any one could tell me how to modify it to get the closest positive number.
Thank you
double minDistance = list.Min(no => Math.Abs(fibo1- no));
double closest = list.First(no => Math.Abs(fibo1- no) == minDistance);
Continue reading...