Home Online Manual
Top
Back: isElement
Forward: isSuperset
FastBack:
FastForward:
Up: sets_lib
Top: Singular Manual
Contents: Table of Contents
Index: Index
About: About this document

D.14.8.6 isSubset

Procedure from library sets.lib (see sets_lib).

Usage:
isSubset(N,M) or N<M ; N,M sets

Return:
bool, 1 if N is a Subset of M or 0 if not

Example:
 
LIB "sets.lib";
list l =1,2;
list j =1,2,3,4;
Set N=l;
Set M=j;
N;
==> {2; 1}
==> Set with 2 elements
==> 
M;
==> {4; 3; 2; 1}
==> Set with 4 elements
==> 
N<M;
==> 1
M<N;
==> 0