Think in Go: Go's alternative to the multiple-inheritance mindset. 15 years ago
The comments in his code are reminiscent of programming by contract (an idea I believe Djikstra himself was fond of). In Go the types of the interfaces are statically checked, which is good (in Python or Ruby, this isn't the case), but the contract the interface represents has to remain in comments and unit tests.
It would be nice to be able to specify tests that every implementor of the Heap interface must pass?