Sha256: 0c61bcb98fde01001d922f3d2ad4f3db372b45896f75ec10c56f245885b1ade3

Contents?: true

Size: 1.06 KB

Versions: 9

Compression:

Stored size: 1.06 KB

Contents

(examples-for ⌊
  ("rounds the given to the nearest integer below"
   (⌊ 12.5)
   12)

  ("rounds the given to the nearest integer below"
   (⌊ 32.32)
   32)

  ("rounds the given to the nearest integer below negatively"
   (⌊ -32.32)
   -33)

  ("alias for 'math-floor"
   (math-floor 3.1415)
   3))

(examples-for ⌈
  ("rounds the given to the nearest integer above"
   (⌈ 25.25)
   26)

  ("rounds the given to the nearest integer above"
   (⌈ 12.5)
   13)

  ("rounds the given to the nearest integer above negatively"
   (⌈ -25.25)
   -25)

  ("alias for 'math-ceiling"
   (math-ceiling 3.1415)
   4))

(examples-for round
  ("rounds the given to the nearest integer"
   (math-round 3.1415)
   3)

  ("rounds the given to the nearest integer"
   (math-round -3.1415)
   -3)

  ("rounds the given to the nearest negative integer"
   (math-round -3.999)
   -4)

  ("rounds the given to the nearest integer"
   (math-round 3.999)
   4)

  ("rounds half-away from zero"
   (math-round 12.5)
   13)

  ("rounds negatively half-away from zero"
   (math-round -1.5)
   -2))

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
nydp-0.6.0 lib/lisp/tests/floor-examples.nydp
nydp-0.5.1 lib/lisp/tests/floor-examples.nydp
nydp-0.5.0 lib/lisp/tests/floor-examples.nydp
nydp-0.4.6 lib/lisp/tests/floor-examples.nydp
nydp-0.4.5 lib/lisp/tests/floor-examples.nydp
nydp-0.4.3 lib/lisp/tests/floor-examples.nydp
nydp-0.4.2 lib/lisp/tests/floor-examples.nydp
nydp-0.4.1 lib/lisp/tests/floor-examples.nydp
nydp-0.4.0 lib/lisp/tests/floor-examples.nydp