going fancy on eliminating for loops with functional calls. No, this is absolutely unnecessary, but I am just having fun. Also, It turns out that the only seemingly elegant way to construct an immutable collection at runtime is using a var. I can live with that.