var (int,int)->int intBinOp; //unused variable for type aliasing

function intBinOp getMultiply() {
    function int multiply(int a, int b)
        a*b;
    multiply
};

function int biasedMultiply(int a, int b) a*b+4;

var intBinOp myMultiply;
myMultiply := getMultiply();
print(myMultiply(5, 8));

myMultiply := biasedMultiply;
print(myMultiply(10, 10));

function int fibonacci(int n) {
    var int start0; start0 := 1;
    var int start1; start1 := 1;

    function int doFibonacci(int n)
        if n == 0 then
            start0
        else
            if n == 1 then
                start1
            else
                doFibonacci(n-1)+doFibonacci(n-2)
            fi
        fi
    ;

    doFibonacci(n)
};

print(fibonacci(1), fibonacci(2), fibonacci(5));
