import random


def generate123(power):
    """
    Generates 3 lists that contain a random number of ones, twos and threes
    :param power: power of 2
    :return: generated lists
    """
    lst123 = []
    for i in range(3):
        experiment = []
        for j in range(2 ** power):
            experiment.append(random.randint(1, 3))
        lst123.append(experiment)
    return lst123