Exercises from Cormen