Count Passengers Aged Over 60
IntuitionEach passenger's detail string contains their age starting at a fixed index. By checking the characters at positions 11 and 12, we determine if the age
# Intuition
Each passenger's detail string contains their age starting at a fixed index. By checking the characters at positions 11 and 12, we determine if the age is greater than 60. If it is, we increment a counter.

# Approach
- Loop through each string in the details vector.

- Check the character at index 11 (tens digit of age).

- If it’s '6', check the character at index 12 (ones digit):

    - If it’s '0', skip (because age is exactly 60).

    - Otherwise, count it (age is >60).

- If the character at index 11 is greater than '6', count it directly (e.g., '7', '8'...).



# Complexity
- Time complexity:

O(n) – where n is the number of passenger detail strings. Each string is checked once.

- Space complexity:

O(1) – only a counter variable is used.

# Code
```cpp []
class Solution {
public:
    int countSeniors(vector<string>& details) {
        int counter = 0;
        for(int i = 0; i < details.size(); i++)
        {
            if(details[i][11] >= '6') 
            {
                if(details[i][11] == '6' && details[i][12] == '0')
                    continue; 

                if(details[i][12] >= '0') 
                    counter++;
            }
        }
        return counter;
    }
};

```
['String', 'Simulation', 'C++']