|
|
|
|
|
by toastal
1314 days ago
|
|
When your code is sufficiently abstract, there often really aren't better variable names than a or x. My experience is that it's about the scope for that variable. If it's in a one-line lambda, then it'll be one letter. If it is going to be used in the next 10 lines or so, make an abbreviator. And it's longer, or particular unclear, spell it all out. Adding extra words don't make BusinessAbstractFactoryIBuilder more readable. |
|
While I understand and agree with this meme[1], I think that's the other extreme, where everything is a Factory Builder thing.
Even so, I would rather too much information than too little, which is what FP programs tend to do. Over-abstraction is also a problem, in my view. Even in a LINQ lambda, for instance, I might write
rather than [1]: https://github.com/EnterpriseQualityCoding/FizzBuzzEnterpris...