Calculate bit by bit...
IntuitionApproachComplexity
Time complexity:

Space complexity:
Code
# Intuition
<!-- Describe your first thoughts on how to solve this problem. -->

# Approach
<!-- Describe your approach to solving the problem. -->

# Complexity
- Time complexity:
<!-- Add your time complexity here, e.g. $$O(n)$$ -->

- Space complexity:
<!-- Add your space complexity here, e.g. $$O(n)$$ -->

# Code
```csharp []
public class Solution {
    public int CountTime(string time) {
        int res = 1;
        // Track '?' in hour position:
        if(time[0] == '?' && time[1] == '?')
            res = 24;
        else if(time[0] == '?')
        {
            res = time[1] <= '3' ? 3 : 2;
        }
        else if(time[1] == '?')
        {
            res = time[0] == '2' ? 4 : 10;
        }

        // Track '?' in min position:
        if(time[3] == '?' && time[4] == '?')
            res *= 60;
        else if(time[3] == '?')
            res *= 6;
        else if(time[4] == '?')
            res *= 10;

        return res;
    }
}
```
['C#']