Implementation of some well-known algorithms based on materials of Robert Sedgewick