fixed up and tested insert:
added extractMinimum/minimum and some emptiness handling