https://github.com/anshsinghsonkhia/check-coprime
NPM package to check if two numbers are coprime
https://github.com/anshsinghsonkhia/check-coprime
Last synced: 6 months ago
JSON representation
NPM package to check if two numbers are coprime
- Host: GitHub
- URL: https://github.com/anshsinghsonkhia/check-coprime
- Owner: AnshSinghSonkhia
- License: apache-2.0
- Created: 2025-03-22T08:54:43.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2025-03-22T09:12:15.000Z (7 months ago)
- Last Synced: 2025-03-22T10:20:12.821Z (7 months ago)
- Language: JavaScript
- Size: 35.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# check-coprime
Checks if two numbers are coprime or not & return true or false (boolean type).
---
## Installation
Install the package via npm:```sh
npm i check-coprime
```
---# Usage
```js
const iscop = require('check-coprime');console.log(iscop.isCoprime(14, 15)); // Output: true
console.log(iscop.isCoprime(14, 21)); // Output: false
console.log(iscop.isCoprime(14, 28)); // Output: false
```