Lazy Properties in Swift

Mohammad Azam
Jun 22 · 3 min read

Swift language allows you to create several different types of properties, including computed, property observers and even lazy properties. In this article, we will learn how lazy properties can provide performance benefits for time consuming calculations.


Let’s consider a scenario, where we are responsible for creating questions for an exam. The Exam struct is…