forked from dfinity/motoko-base
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[DMS-74] Implement missing functionality for set
Add following functions: union(rbSet1 : Set<T>, rbSet2 : Set<T>) : Set<T> intersect(rbSet1 : Set<T>, rbSet2 : Set<T>) : Set<T> diff(rbSet1 : Set<T>, rbSet2 : Set<T>) : Set<T> map<T1>(rbSet : Set<T1>, f : T1 -> T) : Set<T> mapFilter<T1>(rbSet: Set<T1>, f : T1 -> ?T) : Set<T> isSubset(rbSet1 : Set<T>, rbSet2 : Set<T>) : Bool equals (rbSet1 : Set<T>, rbSet2 : Set<T>) : Bool isEmpty<T> (rbSet : Set<T>) : Bool Add tests for the functions above.
- Loading branch information
Showing
3 changed files
with
609 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.