File ListSet.h
↰ Parent directory (ADS/set)
The SET as an unsorted LIST of section 8.2: contains(), insert() and remove() in O( n ), insertNew() in O( 1 ) when the item is known to be absent, the operations in O( n m ), which is optimal when the items can only be compared for equality (exercises 8.1 and 8.2).
Definition (ADS/set/ListSet.h)
Detailed Description
The contracts [see File Contract.h]: insertNew() needs an item that is not there, after insert() the item is there and after remove() it is not, and each operation of two sets gives what its name says; the invariant is that no item is there twice. The operations are defined in ListSet.tpp.
Montresor, Algoritmi e Strutture Dati, 2025, section 8.2, https://algoritmicamente.it/materiali/libro/capitoli/cap08.pdf
- Donato Meoli
Dipartimento di Informatica Universita’ di Pisa
by Donato Meoli
Includes
ADS/Contract.h(File Contract.h)ADS/sequence/List.h(File List.h)ADS/set/SetOperations.h(File SetOperations.h)ADS/set/impl/ListSet.tppalgorithm(File AkraBazzi.h)conceptscstddeffunctionaloptionalstdexceptutilityvector
Namespaces
Classes
Functions
Template Function ADS::setDifference(const ListSet<T>&, const ListSet<T>&)
Template Function ADS::setIntersection(const ListSet<T>&, const ListSet<T>&)
Template Function ADS::setSymmetricDifference(const ListSet<T>&, const ListSet<T>&)
Template Function ADS::setUnion(const ListSet<T>&, const ListSet<T>&)