def extractContent(completeDocument):
    """ Function to separate the document from the preamble(LaTeX formating)
            and the information after the document. It returns an array of strings
            with the parts.

            Args:
                    completeDocument: The first parameter.

            Returns:
                    array: It returns an array of strings with the parts.

    """
    try:
        preamble = completeDocument[:completeDocument.index(
            '\\begin{document}')]
        document = completeDocument[completeDocument.index(
            '\\begin{document}'):completeDocument.index('\\end{document}') +
            len('\\end{document}')]
        epilogue = completeDocument[completeDocument.index(
            '\\end{document}') + len('\\end{document}'):]
    except ValueError:
        print('\\begin{document} or \\end{document} not found.\n')
    return [preamble, document, epilogue]
