Trading Systems Leaders in this forum (automated trading systems) are winning more than 3000 pips in a month (30000$ investing one lot every time). Click here to register and get more information
I'm wondering how i can define one special function that returns an Array
All definable function only return one variable not Array!
can anyone help me?
Thanks
As far as I know there is no way to return an array, but u can use the following technique
double MyFunc(int shift)
{
static double a[100];
static bool firstTime = true;
if (firstTime)
{
firstTime = false;
<fill up the array>
}
return a[shift];
}
As far as I know there is no way to return an array, but u can use the following technique
double MyFunc(int shift)
{
static double a[100];
static bool firstTime = true;
if (firstTime)
{
firstTime = false;
<fill up the array>
}
return a[shift];
}
thanks Elihayun, but this function return only one number (a[shift]) i wants it to return all of "a[]" array not a[shift]
__________________
there wil be nothig for a person exept his efforts (Emam Ali Alayhesalam)
M.A.Gh