wrote some code..
";
return 4;
}
echo "DOING THE FIRST TEST";
for ($i = 0; $i < test('first'); $i++) {
//doStuff
};
echo "";
echo "DOING THE SECOND EMILE COMPACT BLAH TEST";
for ($i = 0; $i < ($num?$num:($num = test('second'))); $i++) {
//doStuff
};
//for ($i = 0; $i < ($num?$num:($num = m
On Tue, 18 Sep 2001 20:56, Niklas Lampén wrote:
> How big difference does it make in speed in these:
>
> for ($i = 0; $i < mysql_num_rows($Results); $i++) {
> blah
> };
> ?>
>
> or
>
> $n = mysql_num_rows($Results);
> for ($i = 0; $i < $n; $i++) {
> blah
> };
> ?>
>
> So actually I'm ask
How big difference does it make in speed in these:
or
So actually I'm asking how much more/less it takes time to do the comparing
against mysql_num_rows() insted of comparing against a variable.
Niklas
3 matches
Mail list logo