S-Expressions are often compared to XML, a key difference being that S-Expressions are far simpler in syntax, therefore being much easier to parse.
""" sexp = [[]] word = '' in_str = False for char in string: if char == '(' and not in_str: sexp.append([])