Implementation of the most popular and other algorithms.