Implement MaxAlgorithm