disaster-math

1.0.11 • Public • Published

Disaster Math

This package posits that a rift in spacetime has ruined arithmetic. 2 + 2 still equals 4, but let's not even get in to anything more complicated than that.

The rules are stupid, so don't bother to understand them!

Use the functions exported from this package -- add, subtract, multiply, and divide -- to derive the "correct" answers in this ridiculous universe.

Exports

The default export from the package is an object containing add, subtract, multiply, and divide keys with the corresponding function.

Each function is also individually exported.

Usage

add

Syntax: add(n1, n2)

Returns: The alternate-universe "sum" of n1 and n2.

subtract

Syntax: subtract(n1, n2)

Returns: The alternate-universe "difference" of n1 and n2.

multiply

Syntax: multiply(n1, n2)

Returns: The alternate-universe "product" of n1 and n2.

divide

Syntax: divide(n1, n2)

Returns: The alternate-universe "quotient" of n1 and n2.

I, for one, welcome the new nonsense math!

I, for one, welcome

Readme

Keywords

none

Package Sidebar

Install

npm i disaster-math

Weekly Downloads

0

Version

1.0.11

License

ISC

Unpacked Size

2.62 kB

Total Files

3

Last publish

Collaborators

  • jeremyrose