Chapter 9. Go with the flow, man! Controlling the flow of your app

This chapter covers

  • How to control the flow of your app
  • The if statement
  • The while statement

You learned back in chapter 5 that the flow of an application—how an application reacts to different events—can be changed when a user interacts with a control, such as by tapping a button. But there are other ways that the flow can be altered that don’t require user intervention like tapping buttons. This chapter introduces some of these ways.

9.1. Control your flow

Controlling the flow of your app is similar to controlling the flow of traffic in the real world. When you’re driving to school or work, you either know where you’re going or you’re following directions of some sort. ...

Get Anyone Can Create an App now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.