OBHT insertion (4)
Implementation (in class OBHT):
private int load = 0; // no. of occupied or formerly- // occupied buckets in this OBHT
public void insert (Object key, Object val) { BucketEntry newest = new BucketEntry(key, val); int b = hash(key); for (;;) { BucketEntry old = buckets[b]; if (old == null) { if (++load == buckets.length) …; buckets[b] = newest; return;