C++, easy DP solution
class Solution {\npublic:\n    int nthUglyNumber(int n) {\n        \n        vector  v (1,1);\n        int i=0,j=0,k=0;\n        while(v.size() < n)\n        {\
class Solution {\npublic:\n    int nthUglyNumber(int n) {\n        \n        vector <int> v (1,1);\n        int i=0,j=0,k=0;\n        while(v.size() < n)\n        {\n            v.push_back(min(v[i] * 2, min(v[j] * 3, v[k] * 5)));\n            if (v.back() == v[i] * 2) ++i;\n            if (v.back() == v[j] * 3) ++j;\n            if (v.back() == v[k] * 5) ++k;\n        }\n        return v.back();\n    }\n};
['Dynamic Programming', 'C++']