#COMPILE EXE "s02_power.exe"
' Sample: Power and square root
FUNCTION PBMAIN() AS LONG
    DIM base AS DOUBLE, result AS DOUBLE, i AS LONG
    base = 2.0
    PRINT "Powers of 2:"
    FOR i = 0 TO 10
        result = base ^ i
        PRINT "2^"; i; " ="; result
    NEXT i
    PRINT "SQR(144) ="; SQR(144)
    FUNCTION = 0
END FUNCTION
