def split_n(string, seps, reg=False):
    r"""Split strings into n-dimensional list.

    ::

        from torequests.utils import split_n

        ss = '''a b c  d e f  1 2 3  4 5 6
        a b c  d e f  1 2 3  4 5 6
        a b c  d e f  1 2 3  4 5 6'''

        print(split_n(ss, ('\n', '  ', ' ')))
        # [[['a', 'b', 'c'], ['d', 'e', 'f'], ['1', '2', '3'], ['4', '5', '6']], [['a', 'b', 'c'], ['d', 'e', 'f'], ['1', '2', '3'], ['4', '5', '6']], [['a', 'b', 'c'], ['d', 'e', 'f'], ['1', '2', '3'], ['4', '5', '6']]]
        print(split_n(ss, ['\s+'], reg=1))
        # ['a', 'b', 'c', 'd', 'e', 'f', '1', '2', '3', '4', '5', '6', 'a', 'b', 'c', 'd', 'e', 'f', '1', '2', '3', '4', '5', '6', 'a', 'b', 'c', 'd', 'e', 'f', '1', '2', '3', '4', '5', '6']
    """
    deep = len(seps)
    if not deep:
        return string
    return [split_n(i, seps[1:]) for i in _re_split_mixin(string, seps[0], reg=reg)]
def split_n ( string , seps , reg = False ) : deep = len ( seps ) if not deep : return string return [ split_n ( i , seps [ 1 : ] ) for i in _re_split_mixin ( string , seps [ 0 ] , reg = reg ) ]
r"""Split strings into n-dimensional list.

    ::

        from torequests.utils import split_n

        ss = '''a b c  d e f  1 2 3  4 5 6
        a b c  d e f  1 2 3  4 5 6
        a b c  d e f  1 2 3  4 5 6'''

        print(split_n(ss, ('\n', '  ', ' ')))
        # [[['a', 'b', 'c'], ['d', 'e', 'f'], ['1', '2', '3'], ['4', '5', '6']], [['a', 'b', 'c'], ['d', 'e', 'f'], ['1', '2', '3'], ['4', '5', '6']], [['a', 'b', 'c'], ['d', 'e', 'f'], ['1', '2', '3'], ['4', '5', '6']]]
        print(split_n(ss, ['\s+'], reg=1))
        # ['a', 'b', 'c', 'd', 'e', 'f', '1', '2', '3', '4', '5', '6', 'a', 'b', 'c', 'd', 'e', 'f', '1', '2', '3', '4', '5', '6', 'a', 'b', 'c', 'd', 'e', 'f', '1', '2', '3', '4', '5', '6']