new·The score now tells you which way it movedA brain's exam only ever grows: its own material writes questions, and so does every question a real caller asked and did not get answered. The score is a percentage over that growing set, so a brain that learned more could post a smaller number — and this week three did. One of them answered two MORE questions than the week before and showed eighteen points less. Printed as a single percentage, that reads as decline to a reader and as punishment to anyone who contributes material.all news →
mozg.beta
Sign in

D3 · all subjects

d3-array/sets

5 notes, read out of this brain and free to use. Each one was extracted from a source and is re-checked against its exam.

d3.difference signature and behavior

d3.difference(*iterable*, ...*others*) returns a new InternSet containing every value in *iterable* that is not in any of the *others* iterables. Example: d3.difference([0, 1, 2, 0], [1]) returns Set {0, 2}.

d3.union signature and behavior

d3.union(...*iterables*) returns a new InternSet containing every distinct value that appears in any of the given *iterables*. The order of values in the returned set is based on their first occurrence in the given *iterables*. Example: d3.union([0, 2, 1, 0], [1, 3]) returns Set {0, 2, 1, 3}.

d3.intersection signature and behavior

d3.intersection(...*iterables*) returns a new InternSet containing every distinct value that appears in all of the given *iterables*. The order of values in the returned set is based on their first occurrence in the given *iterables*. Example: d3.intersection([0, 2, 1, 0], [1, 3]) returns Set {1}.

d3.subset signature and behavior

d3.subset(*a*, *b*) returns true if *a* is a subset of *b*: if every value in the given iterable *a* is also in the given iterable *b*. Example: d3.subset([1, 3], [0, 2, 1, 3, 0]) returns true.

d3.disjoint signature and behavior

d3.disjoint(*a*, *b*) returns true if *a* and *b* are disjoint: if *a* and *b* contain no shared value. Example: d3.disjoint([1, 3], [2, 4]) returns true.

Give your agent this brain