This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
All it takes is the "lazy" keyword in front of the var definition and the object is instantiated when it is first used. Brilliant. | |
*/ | |
class MoralFibre { | |
init() { | |
print("***Creating MoralFibre***") | |
} | |
func actSociallyResponsibly() -> Int { | |
print("supporting local soup kitchen") |