machine learning algorithm written by java.