FT Array Functions

 FT_AADDITION()   Add elements unique of source array to target array
 FT_AAVG()        Average numeric values in an array
 FT_ADESSORT()    Sort an array in descending order
 FT_AEMAXLEN()    Find longest element within an array
 FT_AEMINLEN()    Find shortest element within an array
 FT_AMEDIAN()     Find middle value in array, or average of two middle values
 FT_ANOMATCHES()  Find the number of array elements meeting a condition
 FT_AREDIT()      2 dimensional array editing function using TBrowse
 FT_ASUM()        Sum the elements of an array
 FT_RESTARR()     Restore a Clipper array from a disc file
 FT_SAVEARR()     Save Clipper array to a disc file.

 

FT_ASUM

FT_ASUM()
 Sum the elements of an array

 Syntax

      FT_ASUM( <aArray> [, <nStartIndex> [, <nEndIndex> ] ] ) -> nSum

 Arguments

     <aArray> is the array containing the elements to be summed.

     <nStartIndex> is the first array item to include,
     defaults to first element.

     <nEndIndex> is the last array element to include,
     defaults to all elements.

 Returns

     The sum of the elements of the array or the lengths of the elements.

 Description

     This function is to sum the elements of a numeric array or to sum the
     lengths of a character array.

 Examples

     FT_ASUM(aSubTotals)               // Sum the Entire Array

     FT_ASUM(aSubTotals, 5)            // Sum from the 5th Element On

     FT_ASUM(aSubTotals, , 10)         // Sum the 1st 10 Elements

     FT_ASUM(aSubTotals, 5, 10)        // Sum Elements 5-10

 Source: ASUM.PRG

 Author: David Husnian