Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on How does SQLite work? Part 2: btrees. Parent comment
https://doc.rust-lang.org/std/collections/struct.BTreeMap.ht...
I have found to have btree/sets included very handy.
Suddenly some hacks around hash maps fade away. For example, sort for presentation or check for min/max, dedup data, etc.. Instead of hand code, pick the proper container and COLLECT:
https://doc.rust-lang.org/std/collections/
(ie: You `.collect` at the end of a iterator into your container of choice. Cool)
I think developers just adapt to whatever is provided not matter if is the real fit or not. So is important to provide a good set of types/structures.
I think all langs must give (at least):
- Int, Float, Decimal
- Bool
- Strings (unicode/utf8)
- Dates!
- Enums or better algebraic types
- Vectors, HashMap, Btree, Sets
There are no comments on this comment yet.
https://doc.rust-lang.org/std/collections/struct.BTreeMap.ht...
I have found to have btree/sets included very handy.
Suddenly some hacks around hash maps fade away. For example, sort for presentation or check for min/max, dedup data, etc.. Instead of hand code, pick the proper container and COLLECT:
https://doc.rust-lang.org/std/collections/
(ie: You `.collect` at the end of a iterator into your container of choice. Cool)
I think developers just adapt to whatever is provided not matter if is the real fit or not. So is important to provide a good set of types/structures.
I think all langs must give (at least):
- Int, Float, Decimal
- Bool
- Strings (unicode/utf8)
- Dates!
- Enums or better algebraic types
- Vectors, HashMap, Btree, Sets