Data update
This commit is contained in:
parent
ed705008a8
commit
0df55f9f24
2196 changed files with 32999 additions and 3075 deletions
|
|
@ -0,0 +1,22 @@
|
|||
import "listUtil"
|
||||
|
||||
toBoolStr = function(n)
|
||||
if n == 0 then return "false"
|
||||
return "true"
|
||||
end function
|
||||
|
||||
// create 'extreme' values from 'normal' values
|
||||
negZero = -0
|
||||
inf = 1 / 0
|
||||
negInf = -1 / 0
|
||||
nan = 0 / 0
|
||||
|
||||
// print them and do some arithmetic on them
|
||||
print [inf, negInf, nan, negZero]
|
||||
print [inf + inf, negInf + inf, inf * nan, nan * nan]
|
||||
print [inf/inf, negInf/2, nan + inf, negZero/0]
|
||||
|
||||
// show some comparisons
|
||||
comps = [negZero == 0, inf == -inf, inf == nan, nan == nan]
|
||||
comps.apply @toBoolStr
|
||||
print comps
|
||||
Loading…
Add table
Add a link
Reference in a new issue