A

Admin • 670.22K Points
Coach

Q. Which of the following is a correct computed property?

  • (A) var name = "John"
  • (B) var age: Int = 25
  • (C) var area: Int { return width * height }
  • (D) let value = ()
  • Correct Answer - Option(C)
  • Views: 1
  • Filed under category Swift (iOs)
  • Hashtags:

Explanation by: Admin
This is a valid example of a computed property in Swift.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.