go dp
```\nfunc countTexts(pressedKeys string) int {\n    pressedKeysLen := len(pressedKeys)\n    dp := make([]int, pressedKeysLen + 1)\n    dp[0] = 1\n    dp[1] = 1\
```\nfunc countTexts(pressedKeys string) int {\n    pressedKeysLen := len(pressedKeys)\n    dp := make([]int, pressedKeysLen + 1)\n    dp[0] = 1\n    dp[1] = 1\n    modulo := int(1e9+7)\n    for i := 1; i < pressedKeysLen; i++ {\n        dp[i + 1] = dp[i]\n        if i >= 1 && pressedKeys[i] == pressedKeys[i - 1] {\n            dp[i + 1] = dp[i] + dp[i - 1]\n            if i >= 2 && pressedKeys[i] == pressedKeys[i - 2] {\n                dp[i + 1] = dp[i] + dp[i - 1] + dp[i - 2]\n                if i >= 3 && (string(pressedKeys[i]) == "7" || string(pressedKeys[i]) == "9") {\n                    if pressedKeys[i] == pressedKeys[i - 3] {\n                        dp[i + 1] = dp[i] + dp[i - 1] + dp[i - 2] + dp[i - 3]\n                    }\n                }\n            }\n        }\n        dp[i + 1] %= modulo\n    }\n    return dp[pressedKeysLen] \n}
['Dynamic Programming', 'Go']