Socket
Socket
Sign inDemoInstall

x-number

Package Overview
Dependencies
0
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    x-number

JsDK of Number Class


Version published
Weekly downloads
19
decreased by-5%
Maintainers
1
Install size
2.84 kB
Created
Weekly downloads
 

Readme

Source

x-number :

JsDK of Number Class

Install :

npm install x-number --save;

Features :

1. isEven :

    var n=122;
    n.isEven(); // true
    (n+1).isEven(); //false

2. isOdd :

    var n=123;
    n.isOdd(); // true
    (n+1).isOdd(); //false

3. .. :

Make a range of numbers and out as Array :

   (1)['..'](10);
    // [1,2,3,4,5,6,7,8,9,10]
    (3)['..'](5);
    // [3,4,5]
    (10)['..'](120,30) // increment by 30
    // [40,70,100]

4. toRoman :

var n=4;
n.toRoman();
//-- IV
(61).toRoman();
//--  LXI

5. fromRoman (static):

Number.fromRoman('XXIII');
  // 23

Keywords

FAQs

Last updated on 26 Jul 2016

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc