If you want more precise rounding to the 8th decimal then with-precision is
available for BigDecimals. The literal representation will look just like the
float you wanted.
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send
>>> Java HotSpot(TM) 64-Bit Server VM 11.0.1+13-LTS
>>>
>>> Docs: (doc function-name-here)
>>>
>>> (find-doc "part-of-name-here")
>>>
>>> Source: (source function-name-here)
>>>
>>> Javadoc:
c: (javadoc java-object-or-class-here)
>>
>> Exit: Control+D or (exit) or (quit)
>>
>> Results: Stored in vars *1, *2, *3, an exception in *e
>>
>>
>> user=> (float 0.819869321599107)
>>
>> 0.81986934
>>
>> user=>
>>
>
>>
>> Javadoc: (javadoc java-object-or-class-here)
>>
>> Exit: Control+D or (exit) or (quit)
>>
>> Results: Stored in vars *1, *2, *3, an exception in *e
>>
>>
>> user=> (float 0.819869321599107)
>>
>> 0.81986934
>>
>&g
1.0.1+13-LTS
>
> Docs: (doc function-name-here)
>
> (find-doc "part-of-name-here")
>
> Source: (source function-name-here)
>
> Javadoc: (javadoc java-object-or-class-here)
>
> Exit: Control+D or (exit) or (quit)
>
> Results: Stored i
e-here)
>
> Javadoc: (javadoc java-object-or-class-here)
>
> Exit: Control+D or (exit) or (quit)
>
> Results: Stored in vars *1, *2, *3, an exception in *e
>
>
> user=> (float 0.819869321599107)
>
> 0.81986934
>
> user=>
>
>
> Thanks in ad
For more precision, use `double`, which is a 64-bit double-precision
floating-point value
(float 0.819869321599107) => 0.81986934
(double 0.819869321599107) => 0.819869321599107
https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Double.html
On Sat, Dec 15, 2018 at
11.0.1+13-LTS
>
> Docs: (doc function-name-here)
>
> (find-doc "part-of-name-here")
>
> Source: (source function-name-here)
>
> Javadoc: (javadoc java-object-or-class-here)
>
> Exit: Control+D or (exit) or (quit)
>
> Resu
-name-here)
(find-doc "part-of-name-here")
Source: (source function-name-here)
Javadoc: (javadoc java-object-or-class-here)
Exit: Control+D or (exit) or (quit)
Results: Stored in vars *1, *2, *3, an exception in *e
user=> (float 0.819869321599107)
0.81986934
use