Return to Snippet

Revision: 39032
at January 12, 2011 08:26 by withinmedianl


Initial Code
// returns the total of all numbers in array as 1 number
private function arrayTotal(input:Array):Number
{
	var total:Number = 0;			
	for(var i:Number = 0; i < input.length; i++)
	{
		total += Number(input[i]);
	}
	return total;
}

Initial URL

                                

Initial Description

                                

Initial Title
calculate the total of all numbers in Array

Initial Tags
array

Initial Language
ActionScript 3