input: Write a Python function that, given a 0-indexed string `s`, a string `a`, a string `b`, and an integer `k`, returns a list of indices `i` which meet the following criteria in sorted order:
  
  - `0 <= i <= len(s) - len(a)`
  - `s[i:i + len(a)]` == `a`
  - There exists an index `j` such that:
    - `0 <= j <= len(s) - len(b)`
    - `s[j:j + len(b)]` == `b`
    - `|j - i| <= k`
  
  Make sure the resulting list contains the indices in ascending order.
  
  Examples:
  >>> s = "isawsquirrelnearmysquirrelhouseohmy", a = "my", b = "squirrel", k = 15
  [16, 33]
  >>> s = "abcd", a = "a", b = "a", k = 4
  [0]
  
  Constraints:
  1 <= k <= len(s) <= 10^5
  1 <= len(a), len(b) <= 10
  `s`, `a`, and `b` contain only lowercase English letters.
output: def find_indices(s, a, b, k):
      len_s, len_a, len_b = len(s), len(a), len(b)
      result = []
      
      b_indices = [j for j in range(len_s - len_b + 1) if s[j:j + len_b] == b]
      
      for i in range(len_s - len_a + 1):
          if s[i:i + len_a] == a:
              for j in b_indices:
                  if abs(j - i) <= k:
                      result.append(i)
                      break
                      
      return result