Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


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

Chapter 4. Program Looping

Chapter 4. Program Looping

In Chapter 3 you learned how to make decisions in your program and how to alter its execution based on the results of those decisions. In this chapter, you learn about another fundamental feature of computer programming languages: the capability to repeatedly execute a set of statements.

In many instances, you'll want to iterate a group of statements. For example, you may want to print each file from a list of files. Or you may want to rename each file in a certain folder. Finally, you may have iPhoto images stored in an album that you want to resize. Each of these situations requires you to apply your process—whether it's printing, renaming, or resizing—to each file, in turn. This is done through the process of iteration.


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial