Simple Python Solution || O(1) ||
\n# Code\npython3 []\n\nclass Solution:\n    def countTime(self, t: str) -> int:\n        p=1\n        if t[4]==\'?\':   p*=10\n        if t[3]==\'?\':   p*=6\n
\n# Code\n```python3 []\n\nclass Solution:\n    def countTime(self, t: str) -> int:\n        p=1\n        if t[4]==\'?\':   p*=10\n        if t[3]==\'?\':   p*=6\n        if t[:2]==\'??\': p*=24\n        elif t[1]==\'?\' and t[0]==\'2\':   p*=4\n        elif t[1]==\'?\': p*=10\n        elif t[0]==\'?\' and t[1] in \'456789\':    p*=2\n        elif t[0]==\'?\': p*=3\n        return p\n\n```
['String', 'Python3']