3 ms·
Long variable names are a crutch espoused by those of mediocre ability. Variable names should be explanatory to those who could be expected to comprehend the co
by epo 14y ago
Long variable names are a crutch espoused by those of mediocre ability. Variable names should be explanatory to those who could be expected to comprehend the code, length has nothing to do with it. The domain of this code is physics, if you don't understand what the code is supposed to be doing you shouldn't be messing with it.
That said, a comment at the top explaining the algorithm used and a refence to the literature is all that is really required. A comment explaining what the variables are could be provided if you really must (i.e. you work with those who prize dogma over clarity).