def gen_dataset(
    N,
    DIGIT,
    LESS_OR_EQUAL=True,
):
    """
    any score <0.4 is ok, since +- is easy
    the model have 
    """
    seed(1)
    # Generate N pairs of numbers and their results for different operations
    equations = []
    # operations = ['*', '+', '-', '*', '*']
    operations = ['*']
    for _ in tqdm(range(N)):
        # Helper function to generate a number with 50% chance of being N-digit or N/2-digit
        def get_random_num():
            r = randint(1,3)
            if r == 0:
                # 2 digits less than original
                max_num = 10**(DIGIT-2)
                return randint(0 if LESS_OR_EQUAL else max_num//10, max_num-1)
            elif r == 1:
                # 1 digit less than original
                max_num = 10**(DIGIT-1)
                return randint(0 if LESS_OR_EQUAL else max_num//10, max_num-1)
            else:
                # N-digit number
                max_num = 10**DIGIT
                return randint(0 if LESS_OR_EQUAL else max_num//10, max_num-1)
        # Generate two numbers independently
        num1 = get_random_num()
        num2 = get_random_num()
        # Randomly choose operation
        op = choice(operations)
        # Calculate result based on operation
        if op == '*':
            result = num1 * num2
        elif op == '+':
            result = num1 + num2
        else:  # op == '-'
            assert op == '-'
            # For subtraction, ensure num1 >= num2
            if num1 < num2:
                num1, num2 = num2, num1
            result = num1 - num2
        equations.append((num1, num2, result, op))
    return equations

    any score <0.4 is ok, since +- is easy
    the model have 
    
examples/data_preprocess/arth.py