Formatted code and added new algorithms.