Implement a function that counts the number of substrings of a given string s that contain the substring "bear". The function should account for all possible substrings that can be formed which include at least one occurrence of "bear".
Function Signature
python
def count_bear_substrings(s: str) -> int:
Input Requirements
The function should accept a single argument s, which is a string that can contain lowercase English letters. The length of the string s will be between 0 and 100, inclusive.
Output Requirements
The function should return an integer representing the total count of substrings that contain at least one occurrence of the substring "bear".
Implementation Notes
The function should efficiently search through the string for occurrences of "bear" and count all valid substrings that include these occurrences by calculating the number of possible starting and ending positions of these substrings.
File Requirements
Save your implementation in a file named /app/solution.py.