code: def _lower(string):
      
      if not string:
          return ""
  
      new_string = [string[0].lower()]
      for char in string[1:]:
          if char.isupper():
              new_string.append("_")
          new_string.append(char.lower())
  
      return "".join(new_string)
docs: Custom lower string function.
      Examples:
          FooBar -> foo_bar