Skip to main content

group_ids

Function group_ids 

Source
pub fn group_ids<K: Eq + Hash>(keys: impl IntoIterator<Item = K>) -> Vec<usize>
Expand description

Group ids for keys, one per key: equal keys share a group, and the groups are numbered by first appearance, so the ids run 0..n in order.