Various algorithms implemented for learning purposes