1. Getting Your Feet Wet
Swift was released in 2014, but its development started four years earlier. Chris Lattner, the original author of the LLVM compiler and the director of Apple’s Developer Tools Department, has worked for Apple since 2005. He had to develop Swift in secret for several years and was, amazingly, able to keep it under wraps until its release in June 2014.
This chapter covers the basic building blocks of Swift. It starts with variables and constants, which allow you to reference a storage location by name. With this knowledge, you will be able to store stuff in memory. Swift has a special feature called optionals, which allow you to check for the presence of a value (by determining whether the variable or constant is nil). ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access