def collatzSeq(n, outputSeq = None):
    """
    collatzSeq(int, list) -> list
    accepts two inputs:
    - n (required): the integer against which the conjecture is about to be tested
    - outputSeq (optional): only used during ricursion to store the state of the current test
    """

    if outputSeq is None:
        outputSeq = []

    outputSeq.append(int(n))

    while (n != 1):
        if (n % 2 == 0):
            return collatzSeq(n / 2, outputSeq)
        else:
            return collatzSeq(n * 3 + 1, outputSeq)

    return outputSeq