Algorithm, Implemented by java / c++ / c