diff --git a/Leetcode/CPP/Unique Paths.cpp b/Leetcode/CPP/Unique Paths.cpp new file mode 100644 index 00000000..08d4b563 --- /dev/null +++ b/Leetcode/CPP/Unique Paths.cpp @@ -0,0 +1,22 @@ +//Submitteb by: Ananya Singh (https://github.com/AnanyaSingh2121) +//Problrm statement: https://leetcode.com/problems/unique-paths/ +//Solution Code: + +class Solution { +public: + //using DP. creating a m*n matrix + int uniquePaths(int m, int n) { + int dp[m][n]; + for(int i=0; i