1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#include <stdio.h>

void
variant_left(int i)
{
    puts("I am the code from the left-hand side");
    puts("-------------------------------------");
    if (i >= 42)
        if (i > 42)
            printf("%d is greater than 42", i);
    else 
        printf("%d is less than 42", i);
    puts("\n");
}

void
variant_right(int i)
{
    puts("I am the code from the right-hand side");
    puts("--------------------------------------");
    if (i >= 42)
        if (i > 42)
            printf("%d is greater than 42", i);
        else 
            printf("%d is equal to 42", i);
    puts("\n");
}

void
test(int i)
{
    printf("Test for i = %d\n", i);
    printf("===============\n\n");
    variant_left(i);
    variant_right(i);
}

int
main()
{
    test(41);
    test(42);
    test(43);
}