c++() small DP solution
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\n Describe your approach to solving the problem. \n\n# Complexity\n- Time 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity:\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```cpp []\nclass Solution {\npublic:\n  int lengthAfterTransformations(string s, int t) {\n    long l[26] = {0};\n    for(char ch: s) l[ch-\'a\']++;\n\n    for(long p = l[25]; t--; p = l[25]){\n      for(int i = 25; i; i--) l[i] = l[i-1];\n      l[0] = p, l[1] = (p + l[1]) % 1000000007;\n    }\n\n    long ans = 0;\n    for(int x : l) ans = (ans + x) % 1000000007;\n\n    return ans;\n  }\n};\n```
['C++']