import itertools


def selectSorous (aSorouListList, aF0):
    """
    Takes [[f_1, f_2, ...]_j, ...] and returns the list [g_1, g_2, ...] 
    where each g_i is a sum sorous selected one from each list in aSorouListList + aF_0
    """

    output = []

    combinations = [p for p in itertools.product(*aSorouListList)]

    for combo in combinations:
        sorou = []
        for item in combo:
            sorou += item

        sorou += aF0
        output.append(sorou)

    return output