A = Array
C = Calculation functions
The AverageArray function calculates the arithmetic mean between the elements of an array.
AC10AvergArr (array, average, done)
Parameters:
IN/OUT | VARIABLE TYPE | EXAMPLE NAME | DIM | |
---|---|---|---|---|
IN | ARRSYS | array | L/S | Array to calculate the average of its elements |
OUT | SYSTEM | average | S | The arithmetic mean value calculated |
OUT | GLOBAL | done | F | Flag that indicates that the operation completed |
Is the arithmetic mean of all the values in the array and puts it in the glMedia variable each front of the „gfEsegui“ flag
MAIN: IF gfEsegui gfEsegui = 0 AC10AvergArr (array, average, done) glMedia = average ENDIF