public SortedMap(keys as IList<K>, values as IList<V>):
Creates a sorted map from corresponding key and value lists.
Extra elements are ignored when the lists have different sizes.
| Parameter | Description |
|---|---|
keys | Keys to insert. |
values | Values to associate with the keys. |
values = SortedMap<String, Int>(["b", "a"], [2, 1]) assert values.keys() == i:["a", "b"]