3 ms·
I tend to go with whatever makes the code the most readable; best expresses the intent. If I'm iterating over a list, mapping each element to a lookup somewhere
by RHSeeger 6y ago
I tend to go with whatever makes the code the most readable; best expresses the intent. If I'm iterating over a list, mapping each element to a lookup somewhere, and then removing those that weren't found... that's a good choice for functional. If I'm iterating over a list, if it matches one thing do something, otherwise filter it some more and do something else... I tend to find procedural is easier to read. Maybe it's a transform vs act-on type of thing; I'm not sure.