HashSet::size
pub fn size() -> int Import
Source: use collections::set::{HashSet}; src/collections/set.hy Number of elements.
Called on a HashSet value as value.size(…).
Returns#
int
See also#
HashSet: A set of unique values.HashSet::with_capacity: Create a set with bucket count rounded up to the next power of two (min 8).HashSet::new: Empty set with default capacity 8.HashSet::is_empty: Returnstruewhen the set has no values.HashSet::clear: Remove all elements.HashSet::insert: Insertx; returnstruewhen newly added.HashSet::contains: True whenxis present.HashSet::remove: Removex; returnstruewhen an element was removed.