Tag: dynamic programming

  • Count the number of ways to traverse a Matrix in Swift

    Question: Count the number of ways to traverse a from the top left corner to the bottom, right corner. Limitation: we can only move down or right. Few solutions: first one brute force and second dynamic programming and measuring their time execution below. To compute 10 x 10 matrix with recursive brute force took 1.4…