Month: July 2018
What is a computed property Classes, Structures and Enums may define a computed property. It is a property that does not store value, instead it defines getter and setter to retrieve and set other properties and values indirectly.
What are Any and AnyObject Any and AnyObject are special types for working with nonspecific types. Using Any and AnyObject is not recommended and it is always better to be specific about the types you work with.
How to use as! and as? for downcasting and what are the differences between them
Example of using throws and do-catch and try to handle errors in Swift
Using NSCoding, NSKeyedArchiver and NSKeyedUnarchiver to save array of custom objects to UserDefaults
In fact Array and Dictionary are generic collections, this is why you can create an Array of Int , String or any other type