I found a very interesting technique to multiply trade variations on your blog, but I don't get it right, please can you tell me, what I am doing wrongly.
My expectation based on the bog would be to get print 10, 20, 50... but what I actually get is just 10.
Code:
function run()
{
StartDate=20160104;
StartDate=20160105;
int Period;
int Periods[10] = { 10, 20, 50, 100, 200, 500, 1000, 2000, 5000, 10000 };
while(asset(loop("EUR/USD" )))
{
Period = Periods[optimize(1,1,10,1)-1];
printf("Period: %02d, ",Period) ;
}
}