Data update
This commit is contained in:
parent
4bb20c9b71
commit
cbaf4c4b64
12390 changed files with 318560 additions and 27248 deletions
|
|
@ -0,0 +1,3 @@
|
|||
3.141_592_6
|
||||
1.0E-12
|
||||
0.13
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
printf(1,"Exponential:\t%e, %e, %e, %e\n",{-10.1246,10.2356,16.123456789,64.12})
|
||||
printf(1,"Floating Point\t%03.3f, %04.3f, %+3.3f, %3.3f\n",{-10.1246,10.2356,16.123456789,64.12})
|
||||
printf(1,"Floating Point or Exponential: %g, %g, %g, %g\n",{10,16.123456789,64,123456789.123})
|
||||
|
|
@ -0,0 +1 @@
|
|||
console.log([.1, 1.E+2, 1.0e2, 1.22e-2, 011, 018, 0b101110011, 0xDeadBeef].join(" "));
|
||||
10
Task/Literals-Floating-point/R/literals-floating-point.r
Normal file
10
Task/Literals-Floating-point/R/literals-floating-point.r
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
.1
|
||||
011
|
||||
1.
|
||||
1.0
|
||||
1e2
|
||||
1E+2
|
||||
1e-02
|
||||
0x1P2
|
||||
0xDeadBeef
|
||||
0X2.6EDp3
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
;; Rebol has 64bit decimals like:
|
||||
2.3
|
||||
0.3e+34
|
||||
1.#INF -1.#INF
|
||||
1.#NaN
|
||||
;; It can store 32bit decimals in vectors:
|
||||
#(float32! [1 2])
|
||||
;== #(float32! [1.0 2.0])
|
||||
to-binary #(float32! [1 2])
|
||||
;== #{0000803F00000040}
|
||||
to-binary #(float64! [1 2])
|
||||
;== #{000000000000F03F0000000000000040}
|
||||
|
||||
;; Rebol3 also has "binary" dialect for reading decimals from binary streams
|
||||
binary/read #{0000803F0000000000000040} [f32 f64]
|
||||
;== [1.0 2.0]
|
||||
Loading…
Add table
Add a link
Reference in a new issue