Add
Adds an element to the end of the array.
bool Add(
double element
)
|
Parameters
element
[in] Value of the element to add to the array.
Return Value
Example:
//--- example for CArrayDouble::Add(double)
#include <Arrays\ArrayDouble.mqh>
//---
void OnStart()
{
CArrayDouble *array=new CArrayDouble;
//---
if(array==NULL)
{
printf("Object create error");
return;
}
//--- add arrays elements
for(int i=0;i<100;i++)
{
if(!array.Add(i))
{
printf("Element addition error");
delete array;
return;
}
}
//--- use array
//--- . . .
//--- delete array
delete array;
}
|