17.01.2015, 18:53
Loops: if you know the exact amount use for(), otherwise use while(). You know the exact amount (strlen) so you use for() instead. Actually your topic title already reflected it ("for each"), although Pawn does not have a foreach construct.
pawn Код:
for(new i, j = strlen(string); i < j; i++)
{
string[i] = '*';
}

