Python O(1) easy solution
\nclass Solution:\n    def countTime(self, time: str) -> int:\n        h,m = time.split(":")\n        ans = 0\n        #00:00~23:59\n        #Hours\n        tem
```\nclass Solution:\n    def countTime(self, time: str) -> int:\n        h,m = time.split(":")\n        ans = 0\n        #00:00~23:59\n        #Hours\n        tempH = 1\n        if h =="??":\n            tempH = 24\n        elif h[0] == "?" and h[1]>"3":# "?4","?5","?6","?7"\n            tempH = 2 #0,1\n        elif h[0] == "?" and h[1]<="3":\n            tempH = 3 #0,1,2\n        elif h[1] == "?" and h[0] == "2": #"2?"\n            tempH = 4 #0,1,2,3 \n        elif h[1] == "?" and h[0] <"2": # "1?","0?"\n            tempH = 10 #0,1,2,3,4,5,6,7,8,9\n        tempM = 1\n        \n        #Minutes\n        if m == "??": #\n            tempM = 60 #0~60 min\n        elif m[1] == "?": #"0?"~"5?"\n            tempM = 10 #0,1,2,3,4,5,6,7,8,9\n        elif m[0] == "?": #"?0"\n            tempM = 6 #0,1,2,3,4,5\n        # print(tempH,tempM)\n        return tempH*tempM\n        \n```
['Python', 'Python3']