1.0.9 • Published 2 years ago

nv-set-basic v1.0.9

Weekly downloads
5
License
ISC
Repository
-
Last release
2 years ago

nv-set-basic

  • nv-set-basic

install

  • npm install nv-set-basic

usage

example

const set_bsc = require('nv-set-basic')
> var st0= new Set([1,2,4])
undefined
> var st1= new Set([1,2,5])


> set_bsc.diff(st0,st1)
Set { 4 }
> set_bsc.intersec([st0,st1])
Set { 1, 2 }
> set_bsc.union([st0,st1])
Set { 1, 2, 4, 5 }
>
> set_bsc.is_cmmn_ele(2,[st0,st1])
true
>

> var st = new Set([1,2,3])
undefined
> pop(st)
1
> st
Set(2) { 2, 3 }
>

APIS

  • set_bsc.diff(st0,st1)
  • set_bsc.intersec(array_of_sets)
  • set_bsc.union(array_of_sets)
  • set_bsc.is_cmmn_ele(array_of_sets)
  • set_bsc.is_set(st)
  • set_bsc.eq(st0,st1)
  • set_bsc.pop(st)
  • set_bsc.is_partitions_of(sts,full_set)
  • set_bsc.is_partitions(sts):boolean,Set

LICENSE

  • ISC