note
Rhandom
<blockquote><i>
I cannot tell you how many times I've heard "This program worked fine until the last time we had it modified by our usual programmer, and ever since it works fine most of the time but every now and then doesn't work at all"
</i></blockquote>
<br>
My usual follow up to conversations like these is something like: "Good thing you now have extensive unit tests around your code. You do have unit tests around your code right?"
<br><br>
Any recent system I've worked on has a test suite. "I" understand the code "I" have written and "I" have broken the code when "I" though "I" knew what "I" was doing. Commenting or not has little to do with the situation. It is good that I've had revision control and unit tests to figure out what I broke, how to fix it, and how to check that everything still works.
<br><br>
That really should be done in maintenance mode as well - find all of the existing use cases, wrap them up in a unit test file. Make sure that test file works as you progress in your changes.
<br><br>
Oh - and be sure to leave a comment for why you chose the new algorithm that you implemented. :)
<br><br>
<!-- Node text goes above. Div tags should contain sig only -->
<div class="pmsig"><div class="pmsig-1598">
<font size=1>my @a=qw(random brilliant braindead); print $a[rand(@a)];</font>
</div></div>
614216
614246