LeetCodeFind the Original Typed String IFind the Original Typed String IEasyStringSolution export function possibleStringCount(word: string): number { let answer = 1; for (let i = 1; i < word.length; i++) { if (word[i - 1] === word[i]) { answer += 1; } } return answer; } Complexity Time: O(n)O(n)O(n) Space: O(1)O(1)O(1) LeetCodeFind the Original Typed String Ihttps://leetcode.com/problems/find-the-original-typed-string-i