BEATS 100% in time | 80% in Space complexity |  C++ | Precise
Code\n\nclass Solution {\n    int t[6][51];\n      int solve(int i, int n, int k){\n         if(k==0){\n                return 1;\n            }\n        if(i==
# Code\n```\nclass Solution {\n    int t[6][51];\n      int solve(int i, int n, int k){\n         if(k==0){\n                return 1;\n            }\n        if(i==n){\n                return 0;\n        }\n        if(t[i][k] != -1){\n            return t[i][k];\n        }\n        int cnt1=solve(i,n,k-1);\n        int cnt2=solve(i+1,n, k);\n        return t[i][k]=cnt1+cnt2;\n    }\npublic:\n    int countVowelStrings(int k) {\n        memset(t,-1, sizeof(t));\n       return  solve(0, 5, k);\n    }\n};\n```
['C++']