import re


def parse_query(query):
    """Parse the given query, returning a tuple of strings list (include, exclude)."""
    exclude = re.compile(r'(?<=-")[^"]+?(?=")|(?<=-)\w+').findall(query)
    for w in sorted(exclude, key=lambda i: len(i), reverse=True):
        query = query.replace(w, '')
    query = " " + query
    return re.compile(r'(?<=[+ ]")[^"]+?(?=")|(?<=[+ ])\w+').findall(query), exclude