So Im looking for some smart way to convert any number into a fraction. I need to achieve this:
0.0001 >= my_number >= 0.00001
the problem is that my_number may come as:
194619.98341
as well as:
0.00231134
(examples) so it is possibly any number greater than 0. Im struggling to create a function which will convert it so it belongs to the specified range.