liveBook · Manning

Set operation

A set operation combines, compares, or transforms sets according to the membership of their elements.

How 2 Manning books explain it

Julia as a Second Language

A set operation is an operation that combines or compares collections according to set-membership rules to produce a result collection.

How it is used
Uses membership rules to combine overlapping categories for photo, product-catalog, and bug-tracker searches.
How deep it goes
Explains union, intersection, and directional difference with Venn diagrams and runnable queries, then applies them to filtered sets and dictionary-backed records.
Examples
Works through photo captions, screw product numbers and objects, and bug numbers grouped by assignee, severity, and project.
What you can do after
Apply it via Julia’s `Set`, `union`, `intersect`, and `setdiff` to select records matching combined criteria.

Read how Julia as a Second Language explains set operation →

Python How-To

A set operation is an operation that combines, compares, or otherwise transforms sets according to their element membership.

How it is used
Uses Python sets to compare lists and select members according to containment or shared membership.
How deep it goes
Explains four operations, matching methods and operators, containment checks, iterable flexibility, and unordered results.
Examples
Demonstrates recommended stocks, client portfolios, task sets, and numeric subset and superset assertions.
What you can do after
Apply it via Python set methods and operators to test containment and combine related collections.

Read how Python How-To explains set operation →

Related concepts

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.