01-09-2004, 12:00 AM
Jarulf,Jan 8 2004, 05:08 PM Wrote:The test done is for above 25 and above 40. This gives the ranges 1-25, 26-40 and 41+.actually I put "off by one" in quotes not because of any D1/D2 antecedent, but because this is a common programmer colloquialism.
I would not call it a "off by one" bug since it is of very different nature than the old "off by one" if you mean that the highest value in a range was not pickable.
When a programmer isn't "sharing", i.e. working solo and no one else is ever going to read their code, then their own personal standards of meaning for labeling conventions are acceptable.
When a programmer is sharing, that is others will see and perhaps need to actually understand their work, labeling conventions are as important as the code itself.
Even before making D2 a modders game, the team working on D2 was large. Thus "shared" standards should apply.
We have columns of data saying "1", "25" and "40". It is not consistant for these to mean > as opposed to >= because then the column saying "1" would mean 2.., and the meaning for a value of 1 would be undefined.
Since, as I've pointed out, I consider such a lack of clarity a serious issue, I most certainly did mean to say Blizz had commited an "off by one" error. Had the first column been labeled "0" my new objection would be aesthetic (i.e. 0 is fine for programmers, but "ordinary" folk would be manipulating the data tables also, and most people don't seem to have grokked this fine invention of Arab mathematicians).
However, if the first column is "1", the remaining should be "26" and "41".
I suspect it is likely, however, that the person making the data actually thought, as "we" did, that the breakpoints would be 25+ and 40+, and the implementation simply does not coincide. If this speculation is correct, then this situation is well and truly an "off by one" error, and not just a lesser nit about clarity.
However, the very fact that we can not derive the truth of this from the available evidence points out just how important naming clarity is.
As usual, imo, ymmv, tgif (well, GMT at least), hibhpiafcf (and if you can get that one, I'll be amazed), etc. :)
"He's got demons? Cool!" -- Gonzo, Muppet Treasure Island
"Proto-matter... an unstable substance which every ethical scientist in the galaxy has denounced as dangerously unpredictable." -- Saavik, Star Trek III
"Mom! Dad! It's evil! Don't touch it!" -- Kevin, Time Bandits
"Proto-matter... an unstable substance which every ethical scientist in the galaxy has denounced as dangerously unpredictable." -- Saavik, Star Trek III
"Mom! Dad! It's evil! Don't touch it!" -- Kevin, Time Bandits