ContainsExactly
ContainsExactly[e1,e2]
yields True if e1 contains exactly the same elements as e2.
ContainsExactly[e2]
is an operator form that yields True when the object to which it is applied contains exactly the same elements as e2.
Examples
open allclose allBasic Examples (2)
Scope (4)
Check whether certain chemicals contain exactly certain elements:
Use ContainsExactly in operator form:
Find music works composed in 1982 by Bernie Taupin and Elton John:
ContainsExactly works with associations:
Options (2)
SameTest (2)
By default, ContainsExactly considers elements to be the same if they are identical:
Changes of units are taken into account, as long as they represent the exact same quantity:
Numerical approximations are not considered as the same object:
Use Equal as the comparison function to have numerical tolerance:
Applications (1)
Properties & Relations (3)
ContainsExactly[list1,list2] is equivalent to testing for equality as sets:
ContainsExactly is a symmetric function of its arguments. That is, ContainsExactly[list1,list2]==ContainsExactly[list2,list1]:
ContainsExactly[list1,list2] is equivalent to And[ContainsAll[list1,list2],ContainsOnly[list1,list2]]:
Text
Wolfram Research (2015), ContainsExactly, Wolfram Language function, https://reference.wolfram.com/language/ref/ContainsExactly.html.
CMS
Wolfram Language. 2015. "ContainsExactly." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/ContainsExactly.html.
APA
Wolfram Language. (2015). ContainsExactly. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/ContainsExactly.html