An open API service indexing awesome lists of open source software.

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

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
```