Refactoring and adding Docstrings
dist_array_2d Done!