Committing all search algorithms in java