Advertisement
backlight0815

Untitled

Jun 11th, 2022
199
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Swift 0.63 KB | None | 0 0
  1. class Family {
  2.   var name:String = ""
  3.   var number:Int = 8
  4.   var position:String = ""
  5.  
  6.  func Intro(){
  7.    if number > members.number {
  8.      print("Your family member seem like look enough")
  9.    } else{
  10.      print("It is crazy when you too many of family members here?")
  11.    }
  12.      print(members.number)
  13.  
  14.  }
  15.  
  16. }
  17.  
  18. let members = Family()
  19. members.name = "Sua Kai Young"
  20. members.number = 4
  21. members.position = "Housewife"
  22.  
  23. print(members.name)
  24. print(members.number)
  25. print(members.position)
  26.  
  27. print("My name is \(members.name) and my family member number is \(members.number) and my mother's responsible is \(members.position)")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement