Part II The Basics

Programs execute code in a specific order. Writing software means having control over the order in which code executes. Programming languages provide control flow statements to help developers organize the execution of their code. This part of the book introduces the concepts of conditionals and loops to accomplish this task.

It will also show you how Swift represents numbers and text – often called strings – in code. These types of data are the building blocks of many applications. By the end of these chapters, you will have a good understanding of how numbers and strings work in Swift.

Last, this part of the book introduces the concept of optionals in Swift. Optionals play an important role in the language ...

Get Swift Programming: The Big Nerd Ranch Guide 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.