3 ms·
For most people's uses, it's the same. Certainly, there can be performance benefits if your language's implementation uses lazy evaluation and you have a very l
by NateDad 12y ago
For most people's uses, it's the same. Certainly, there can be performance benefits if your language's implementation uses lazy evaluation and you have a very large list and you only need to evaluate a small portion of the list... but in my experience, that is very rarely the case in real programs.
- jacques_chester 12y ago> For most people's uses, it's the same. I look forward to seeing how I can chain multiple operations on a set into a single line of Go.
- NateDad 12y agoCramming a lot of logic into a single line of code is an anti-pattern and not a goal of the go language. Also see the aforementioned "the answer is to write a loop".
- jacques_chester 12y agoAs I said, I've seen people say "it's the same". It is not the same. Saying "supports higher level and lower level" programming when you don't actually support most higher level programming primitives is also, from my point of view, untrue. Go's design choices are what they are, which is fine. But I just see a lot of people who argue, in all seriousness, that a loop has the same level of abstraction as map, filter etc. It simply doesn't.
- NateDad 12y agoI can put the loop a function if you want a nice compact version with a friendly name. Not sure what level of abstraction you're missing.
- jacques_chester 12y agoI can label a GOTO as well. That languages are turing equivalent doesn't mean that they operate at the same level of abstraction; trying to pass one off as being "the same" as another is just silly.