Skip to content
Node module for checking if a number is prime
JavaScript
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore
LICENSE
README.md
example.js
index.js
package.json
test.js

README.md

check-prime

Node module for checking if a number is prime

Install

$ npm install --save check-prime

Usage

var isPrime = require('check-prime');

isPrime(2);
// => true

isPrime(7);
// => true

isPrime(1);
// => false
You can’t perform that action at this time.