This forum is now read-only. Please use our new forums at discuss.codecademy.com.

For Loops in PHP Forum

View Course » View Exercise

284 points
965ea4625223dc3de3315ed89df42484?s=140&d=retro
Submitted by
inaitana
over 2 years ago

Error in 3/7

for ($i = 0; $i < 11; $i++) {
    echo $i;
}

This outputs numbers from 0 to 10, not from 1 to 10.

This is very misleading, since to solve the exercise (from 10 to 100) the starting condition needs to be $i=10, not $i=0, as this example would lead the student to believe.


1 vote

permalink

Well you are right

778 points
57efa97b2ddfa3e3e3000010_206519263
Submitted by
Paritosh Kulkarni
over 2 years ago