Here dist is a variable but inside the for loop its used as an array in afl programming
dist = 1.5*ATR(10);
for(i = 0;i < BarCount; i++ )
{
if( Buy[i] ) PlotText( "Buy\n@" + C[ i ], i, L[ i ]-dist[i], colorGreen );
if( Sell[i] ) PlotText( "Sell\n@" + C[ i ], i, H[ i ]+dist[i], colorRed,
colorYellow );
}