def linkText(text):
    if text:
        if result:
            if result[(- 1)].tail:
                result[(- 1)].tail += text
            else:
                result[(- 1)].tail = text
        elif parent.text:
            parent.text += text
        else:
            parent.text = text
def linkText(text):
    if text:
        if result:
            if result[(- 1)].tail:
                result[(- 1)].tail += text
            else:
                result[(- 1)].tail = text
        elif parent.text:
            parent.text += text
        else:
            parent.text = text