Coding up the algorithms in CLRS, "Introduction to Algorithms"