public void delete(String key)
    {
        if (!isPresent(key)) {
            // TODO test this
            throw new IllegalArgumentException("key is not present");
        }

        for (int bucketIndex : getHashBuckets(key)) {
            Bucket bucket = new Bucket(bucketIndex);
            if(bucket.value >= 1 && bucket.value < MAX_COUNT) {
                bucket.set(bucket.value - 1);
            }
        }
    }