Many functions in PHP are implemented using for loops. For example, string conversion problems, calculating the number of executions, etc. I feel that the for loop is very useful and can solve many underlying problems. Can any expert summarize the use of for loops in programming?
擁有18年軟件開發(fā)和IT教學(xué)經(jīng)驗(yàn)。曾任多家上市公司技術(shù)總監(jiān)、架構(gòu)師、項目經(jīng)理、高級軟件工程師等職務(wù)。 網(wǎng)絡(luò)人氣名人講師,...
In fact, instead of asking what the for loop can do, it is better to ask what the loop can do in programming:
http://www.cnblogs.com/swiftm...
http://www.jianshu.com/p/7b28...
Without loops and recursion, there is no program to write.
Looping is to do those repetitive tasks for you, and the biggest advantage of computers over people is looping. If there is no looping, the mobile phones and computers around you can be thrown away! -->Joke, without loops, how could there be computers and mobile phones? !