-
Notifications
You must be signed in to change notification settings - Fork 0
Types Methods
Science Spot edited this page Oct 19, 2020
·
1 revision
const { sizeType } = require('node-set-theory');
// Will return 'empty', 'singleton' or 'many' based on the size of the set...
sizeType([]); // Will return 'empty' which means null set
sizeType([1]); // Will return 'singleton' which means it has only 1 element
sizeType([1, 2, 3]); // Will return 'many' which means it has more than 1 element