Library

Program

program prog
// variables and constants can be here// this function is the entrypoint
function main()
printColorName(colorEnumeration.RED);
end
function printColorName(color colorEnumeration)case(color)
when(colorEnumeration.RED)
syslib.writestdout("red");
when(colorEnumeration.GREEN)
syslib.writestdout("green");
when(colorEnumeration.BLUE)
syslib.writestdout("blue");
otherwise
syslib.writestdout("unknown");
end
end
// other functions can go here
end