algorithms: Update docstring for diff()