Guys what does this mean????

 

HI Guys ,

I wonder if someone can please explain what does this code mean...

/----

for(i = limit; i >= 0; i--)

{

if(High > LastHigh)

LastHigh = High;

//----

if(Low < LastLow)

LastLow=Low;

if(TimeDay(Time) != TimeDay(Time))

{

Print(DoubleToStr(Close, Digits));

Print(DoubleToStr(High[0], Digits));

Print(DoubleToStr(Low[0], Digits));

Thanks

 

/----

for(i = limit; i >= 0; i--) For each Bar starting at the oldest

{

if(High > LastHigh) If the previous bar is a new high

LastHigh = High; Cache the new High

//----

if(Low < LastLow) If the previous bar is a new low

LastLow=Low;Cache the new low

if(TimeDay(Time) != TimeDay(Time))

{ If this bar is the start of a new day, print the open close and high

Print(DoubleToStr(Close, Digits));

Print(DoubleToStr(High[0], Digits));

Print(DoubleToStr(Low[0], Digits));

Basically it's collecting the highest high and the lowest low from limit bars back in time.

 
4xCoder:
/----

for(i = limit; i >= 0; i--) For each Bar starting at the oldest

{

if(High > LastHigh) If the previous bar is a new high

LastHigh = High; Cache the new High

//----

if(Low < LastLow) If the previous bar is a new low

LastLow=Low;Cache the new low

if(TimeDay(Time) != TimeDay(Time))

{ If this bar is the start of a new day, print the open close and high

Print(DoubleToStr(Close, Digits));

Print(DoubleToStr(High[0], Digits));

Print(DoubleToStr(Low[0], Digits));

Basically it's collecting the highest high and the lowest low from limit bars back in time.

Tanks 4xcoder for you help,