December 2024
Beginner to intermediate
584 pages
12h 58m
English
In the previous chapter, you learned how to group instruction sequences using functions and closures.
It’s time to think about how to represent complex objects in your code. For example, think about a car. You could use a String constant to store a car name and a Double variable to store a car price, but they are not associated with one another. You’ve seen that you can group instructions to make functions and closures. In this chapter, you’ll learn how to group constants and variables in a single entity using classes and structures, and how to manipulate them. You’ll also learn how to use enumerations to group a set of related values.
By the end of this chapter, you’ll have learned how to create and initialize ...
Read now
Unlock full access