write-a-hash-table icon indicating copy to clipboard operation
write-a-hash-table copied to clipboard

Corrected deletion of items

Open mbrlabs opened this issue 8 years ago • 0 comments

Currently the count variable would always decrement even if the key is not in the table. You can also return from the function directly if a deletable item has been found since keys are unique. Typically one would also return a status code about weather the the item has been deleted (found) or not.

mbrlabs avatar Sep 01 '17 21:09 mbrlabs