• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 8. Meeting HTML's Powerful Friends > Here we go loop‐de‐loop

Here we go loop‐de‐loop

Another item commonly used in programming is the loop. A loop executes lines of code a given number of times. The most commonly used loops are while and for. A while loop executes lines of code while a certain condition is true. A for loop specifies how many times the lines of code repeat. Listing For This Loop shows the basic structure of a for loop.

							For This Loop
							
for (initial value; test; increment)
{
    execute this code;
}



PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint