bbodi/notecalc3

Feature request: keyed lists

Opened this issue · 1 comments

While it's possible to store collections of data in matrices, it would be nice if we could store collections into maps with keys. This allows for convenient aggregate operations:

item counts = [a: 1, b: 2, c: 3, d: 4]
weight per item = 10g

item weights = item counts * weight per item
item weights.d == 40g
bbodi commented

I can do this:

item weights = [1, 2, 3, 4] * 10g 
nth(item weights, 3)       

Unfortunately your exact request is out of scope and I don't think I will implement it, though I keep the issue open.