feat(floor): Provide example of op-centric organization
This commit is contained in:
parent
fe54bc6004
commit
7d1a435aa0
11 changed files with 65 additions and 8 deletions
|
@ -51,4 +51,12 @@ describe('complex', () => {
|
|||
math.complex(4n, 5n))
|
||||
})
|
||||
|
||||
it('computes floor', () => {
|
||||
assert.deepStrictEqual(
|
||||
math.floor(math.complex(19, 22.7)),
|
||||
math.complex(19, 22))
|
||||
const gi = math.complex(-1n, 1n)
|
||||
assert.strictEqual(math.floor(gi), gi) // literally a no-op
|
||||
})
|
||||
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue