I want to write an algorithm that returns all distinct straight paths of length n from a given nxn matrix, including along the principal and secondary diagonals