nMonitor needs to hold the buffer:
ubuffer:
array[0..k-1] of items;
nneeds two condition variables:
unotfull:
true when buffer is not full
unotemty:
true when buffer is not empty
nneeds buffer pointers and counts:
unextin:
points to next item to be appended
unextout:
points to next item to be taken
ucount:
holds the number of items in buffer
u