{"_id":"@berriz44/mathext","_rev":"3-e180eb0c105822378299bf2a5ba60456","name":"@berriz44/mathext","dist-tags":{"latest":"1.0.3-readme"},"versions":{"1.0.0":{"name":"@berriz44/mathext","version":"1.0.0","description":"","main":"mod.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"publishConfig":{"access":"public"},"keywords":["math"],"author":{"name":"berriz44"},"license":"Unlicense","_id":"@berriz44/mathext@1.0.0","_nodeVersion":"18.14.2","_npmVersion":"9.6.2","dist":{"integrity":"sha512-t0D3Sr6rU7gsYLLbjQJLITTdkCj29x3qI0WZ4ejxcSl6KWz8d8lcuwBjKuVGJ9gk98LU20YC5CUQ1entCCOiHg==","shasum":"f1fc55760e83fc8fa4cbc1f51cff2e9779288f38","tarball":"https://registry.npmjs.org/@berriz44/mathext/-/mathext-1.0.0.tgz","fileCount":3,"unpackedSize":14153,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGYX9fh38MJcXFbwZR6YBp40W5ajaX+eWsav2ovaqZ/0AiB3ZsrlEbLuRxAqDfJehyP0Uo9bQgNv+BtSisQYDe7E2A=="}]},"_npmUser":{"name":"berriz44","email":"victorstefan.costin@gmail.com"},"directories":{},"maintainers":[{"name":"berriz44","email":"victorstefan.costin@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mathext_1.0.0_1696491377619_0.8703783092874751"},"_hasShrinkwrap":false},"1.0.2":{"name":"@berriz44/mathext","version":"1.0.2","description":"[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://github.com/the-one-with-raspberry/mathext)\r [![GitHub last commit (master)](https://img.shields.io/github/last-commit/the-one-with-raspberry/mathext/master)](https://github","main":"mod.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1","build":"tsc && more add-to-tsc-file.txt >> mod.js"},"publishConfig":{"access":"public"},"keywords":["math"],"author":{"name":"berriz44"},"license":"Unlicense","gitHead":"e70eba8b318101ee709614bd87052982f620cf56","_id":"@berriz44/mathext@1.0.2","_nodeVersion":"18.14.2","_npmVersion":"9.6.2","dist":{"integrity":"sha512-cg6qPGUCsKX8Bu2XChy64k1fOPfUQOB4GDRD4FfNr8As2dIEkDxefYdjWosUPb8rdFXtgQQ+QfjsY5lgzGhKhA==","shasum":"97d7db42ad44f0d3820748bf2c679d2cde2ae9ba","tarball":"https://registry.npmjs.org/@berriz44/mathext/-/mathext-1.0.2.tgz","fileCount":6,"unpackedSize":18729,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDw40p4cmEhHBhLvJ6doATwBRBFr2jra8TveDqIr2MwqwIhAJSRX8a8E0SgSLKxZ4GVozJIsLIN93m/l1zn8vYCTI71"}]},"_npmUser":{"name":"berriz44","email":"victorstefan.costin@gmail.com"},"directories":{},"maintainers":[{"name":"berriz44","email":"victorstefan.costin@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mathext_1.0.2_1696599665284_0.5900483133313574"},"_hasShrinkwrap":false},"1.0.3":{"name":"@berriz44/mathext","version":"1.0.3","description":"[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://github.com/the-one-with-raspberry/mathext)\r [![GitHub last commit (master)](https://img.shields.io/github/last-commit/the-one-with-raspberry/mathext/master)](https://github","main":"mod.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1","build":"tsc && more add-to-tsc-file.txt >> mod.js","prepublish":"npm run build"},"publishConfig":{"access":"public"},"keywords":["math"],"author":{"name":"berriz44"},"license":"Unlicense","gitHead":"a963117d8f12254aecb6df18e43dac4c3e3c00de","_id":"@berriz44/mathext@1.0.3","_nodeVersion":"18.14.2","_npmVersion":"9.6.2","dist":{"integrity":"sha512-xjIDHTuLuIMWLwIAcWA7my/uumRyWfHKgmO0qvcnFFn4VhTG0WRkycR+3IvApetHiTfAoHdlCCmCFAxpeVXvow==","shasum":"3bd7a69aa329077f89d32aef4874b234d1d2aa76","tarball":"https://registry.npmjs.org/@berriz44/mathext/-/mathext-1.0.3.tgz","fileCount":6,"unpackedSize":19990,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFnAOn7Zk5dZSCY1I/OL09x7J2+hl6Z4Xn2qrbcvB6NwAiBwrtI+6RSVj/ODjLEImZ1+VDaVbd/IW4MjDUWXTiUFHw=="}]},"_npmUser":{"name":"berriz44","email":"victorstefan.costin@gmail.com"},"directories":{},"maintainers":[{"name":"berriz44","email":"victorstefan.costin@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mathext_1.0.3_1696660540860_0.1283453650206885"},"_hasShrinkwrap":false},"1.0.3-readme":{"name":"@berriz44/mathext","version":"1.0.3-readme","description":"[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://github.com/the-one-with-raspberry/mathext)\r [![GitHub last commit (master)](https://img.shields.io/github/last-commit/the-one-with-raspberry/mathext/master)](https://github","main":"mod.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1","build":"tsc && more add-to-tsc-file.txt >> mod.js","prepack":"npm run build","pack":"npm pack"},"publishConfig":{"access":"public"},"keywords":["math"],"author":{"name":"berriz44"},"license":"Unlicense","gitHead":"dfd66a4c0a91bf6ce6d7bd056f357ec67f618e3a","_id":"@berriz44/mathext@1.0.3-readme","_nodeVersion":"18.14.2","_npmVersion":"9.6.2","dist":{"integrity":"sha512-lbmp061NSbtNZlkgimml0BECt6SOF3MHRyTRz3HPIJetAA7fm6hWh+9pAlDGfn4lnaD4r27IaE0m3qs5YrThwQ==","shasum":"cdccc448e83c0791b5f543fddcdf9252680050ec","tarball":"https://registry.npmjs.org/@berriz44/mathext/-/mathext-1.0.3-readme.tgz","fileCount":6,"unpackedSize":20164,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIC045owjazoqm0YaZnj2jbMyQuoCazvXGI736STtLPjhAiBwPF7YTsBJcxtyjQi1xYY/EtJCRYUtVDCt9FZbKOMQfA=="}]},"_npmUser":{"name":"berriz44","email":"victorstefan.costin@gmail.com"},"directories":{},"maintainers":[{"name":"berriz44","email":"victorstefan.costin@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mathext_1.0.3-readme_1696678584745_0.2958927857212188"},"_hasShrinkwrap":false}},"time":{"created":"2023-10-05T07:36:17.549Z","1.0.0":"2023-10-05T07:36:17.833Z","modified":"2023-10-07T11:36:25.109Z","1.0.2":"2023-10-06T13:41:05.460Z","1.0.3":"2023-10-07T06:35:41.086Z","1.0.3-readme":"2023-10-07T11:36:24.935Z"},"maintainers":[{"name":"berriz44","email":"victorstefan.costin@gmail.com"}],"keywords":["math"],"author":{"name":"berriz44"},"license":"Unlicense","readme":"# mathext\r\n\r\n[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://github.com/the-one-with-raspberry/mathext)\r\n[![GitHub last commit (master)](https://img.shields.io/github/last-commit/the-one-with-raspberry/mathext/master)](https://github.com/the-one-with-raspberry/mathext/tree/master)\r\n[![GitHub issues](https://img.shields.io/github/issues/the-one-with-raspberry/mathext)](https://github.com/the-one-with-raspberry/mathext/issues)\r\n[![npm](https://img.shields.io/npm/v/%40berriz44%2Fmathext)](https://www.npmjs.com/package/@berriz44/mathext)\r\n[![GitHub Repo stars](https://img.shields.io/github/stars/the-one-with-raspberry/mathext)](https://github.com/the-one-with-raspberry/mathext)\r\n[![npm bundle size](https://img.shields.io/bundlephobia/minzip/%40berriz44%2Fmathext)](https://bundlephobia.com/package/@berriz44/mathext@1.0.3)\r\n\r\n\r\n`mathext` is an extension of the `math` interface in JavaScript.\r\n\r\nhow to install:\r\n\r\n```bash\r\nnpm install @berriz44/mathext\r\n```\r\n\r\nusage:\r\n\r\n```js\r\nconst MathExt = require('@berriz44/mathext')\r\n```\r\n\r\n# items\r\n\r\n## `MathExt.numberRow: number | string | Array<number>`\r\n\r\n### description:\r\n\r\nmakes a row of numbers\r\n\r\n### arguments:\r\n\r\n1. `end: number` | to what number should it count\r\n2. `start: number` | what number should it start with. defaults to 1.\r\n3. `step: number` | how much to increment each number. defaults to 1. affected by `start` and `end`.\r\n4. `datatype: number | string | Array<any>` | can be any number, array or string. defaults to array. determines the return type of the function.\r\n\r\n### returns:\r\n\r\na `number`, `string`, or `Array<number>` representing a row of numbers\r\n\r\n### examples:\r\n\r\n```js\r\nMathExt.numberRow(10, 1)\r\n// [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]\r\ntypeof MathExt.numberRow(10, 1)\r\n/// Array<number>\r\n```\r\n\r\n```js\r\nMathExt.numberRow(11, 1, 2)\r\n// [1, 3, 5, 7, 9, 11]\r\n```\r\n\r\n```js\r\nMathExt.numberRow(10, 1, 1, \"\")\r\n// \"12345678910\"\r\ntypeof MathExt.numberRow(10, 1, 1, \"\")\r\n// 'string'\r\n```\r\n\r\n```js\r\nMathExt.numberRow(10, 1, 1, 0)\r\n// 12345678910\r\ntypeof MathExt.numberRow(10, 1, 1, 0)\r\n// 'number'\r\n```\r\n\r\n## `MathExt.isPositive: boolean`\r\n\r\n### description:\r\n\r\nsays if a number is positive or not\r\n\r\n### arguments:\r\n\r\n`i: number` | which number to know whether it is positive or negative\r\n\r\n### returns:\r\n\r\n`true` if `i` is positive, `false` if `i` is negative\r\n\r\n### examples:\r\n\r\n```js\r\nMathExt.isPositive(77)\r\n// true\r\n```\r\n\r\n```js\r\nMathExt.isPositive(-24)\r\n// false\r\n```\r\n\r\n### examples:\r\n\r\n## `MathExt.infinity: number`\r\n\r\n### description:\r\n\r\nreturns infinity or negative infinity based on a parameter\r\n\r\n### arguments:\r\n\r\n`side: number` | any number. affects the return value.\r\n\r\n### returns:\r\n\r\n`infinity` if `side` is a positive number and `-infinity` if `side` is a negative number\r\n\r\n### examples:\r\n\r\n```js\r\nMathExt.infinity(1)\r\n// Infinity\r\n```\r\n\r\n```js\r\nMathExt.infinity(-1)\r\n// -Infinity\r\n```\r\n\r\n## `MathExt.turnStringArrayToNumberArray: Array<number>`\r\n\r\n### description:\r\n\r\nturns a string array into a number array\r\n\r\n### arguments:\r\n\r\n`arr: Array<string>` | the array to convert\r\n\r\n### returns:\r\n\r\nan `Array<number>` with numbers from the `arr` parameter\r\n\r\n### examples:\r\n\r\n```js\r\nMathExt.turnStringArrayToNumberArray([\"10\", \"4\", \"9\", \"fffg\"])\r\n// [10, 4, 9, NaN]\r\n```","readmeFilename":"README.md","description":"[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://github.com/the-one-with-raspberry/mathext)\r [![GitHub last commit (master)](https://img.shields.io/github/last-commit/the-one-with-raspberry/mathext/master)](https://github"}