José, I just watched your Twitch stream of day 10 of Advent of Code and, as a fan of for comprehensions, I enjoyed the time you spent discussing potential extensions of them. I recall learning about the reduce option the last time you streamed AoC. I’d like to start a thread to discuss some of those things you discussed. Twitch
I have found myself treating for more like with and sometimes using = in the clauses. My initial thoughts are that it is not a big problem to expect that level of understanding in order to use a group_by or sort_by option. However, I might also be convinced of group_by and sort_by options being a function if they could receive a binding.
I also am intrigued by your suggestion of with. My first thought went to let (allowing multiple of those) in which case they are mutable and the for comprehension can return them as a second binding param.
More thoughts and discussion?
thanks for the feedback!





















