C
@chrismcb said:@fennec said: if(strlen(words)<256)That reminds me... We just had a bug where we weren't cleaning up an array. So my fellow "developer" went in and fixed the bug:count = 0; //count is how many items are in the arrayfor(int i = 0; i<256; i++ array[i] = 0; // whatever, clear out this item I looked at this code, and I asked him "What is 256?" He told me "its the size of the array."Sure enough the array is defined: int array[256];Great, I suggested a slightly better alternative, lets only delete the items we placed in the array. And while we are at it, lets fix the possible buffer over run (the guy filling the array checks to see that we are out of bounds)I gave him some sample code using sizeof(array)... His response: "The array is hardcoded so I don't need to calculate the size."!!!Guys, seriously, quit making baby coder Jesus cry.