Created
September 23, 2021 19:28
-
-
Save MoussaHellal/0fe74c3dc49a434848ec057f5d52e638 to your computer and use it in GitHub Desktop.
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
class Human { | |
static var name = "Mousa" | |
class var age : Int { | |
return 27 | |
} | |
} | |
// Type Method : we accessed both properties without even creating an instance of Human Class. | |
print(Human.name) | |
print(Human.age) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment