This site does not allow itself to be embedded. You can still read it on the original site — the toolbar below keeps your place in the directory.
I've previously blogged about how much I like Zig's getOrPut hashmap method. As a brief recap, we can visualize Zig's hashmap as two arrays: keys: values: -------- -------- | Paul | | 1234 | @mod(hash("Paul"), 5) == 0 -------- -------- | | | | -------- -------- | | | | -------- -------- | Goku | | 9001 | @mod(hash("Goku"), 5) == 3 -------- -------- | | | | -------- -------- When we call…
Comments
Nothing yet. Say the first thing.
Sign in to join the conversation.