def _mid ( string , start , end = None ) : if end is None : end = len ( string ) return string [ start : start + end ]
python left right mid string
Returns a substring delimited by start and end position .
def _mid(string, start, end=None):
    """
    Returns a substring delimited by start and end position.
    """
    if end is None:
        end = len(string)
    return string[start:start + end]