Maybe my question seems primary, But actually it is not. I claim that I can do everything is done with for() by while(), And conversely. So really when while() is useful when there is for()? I need to a example that I can do that by for() and I can not do that by while(). There is? I think there is not ...!
Here is the structure:
for (init counter; test counter; increment counter) {
code to be executed;
}
init counter;
while (test counter) {
code to be executed;
increment counter;
}
see? they are exactly the same, Now I want to know why php has both of them?