Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Could someone please help me with some Swift programming questions? Question 1 A

ID: 3602048 • Letter: C

Question

Could someone please help me with some Swift programming questions?

Question 1

Any type that satisfies the requirements of a protocol is said to ____________ that protocol.

Question 2

If a class has a superclass, list the superclass name ____________ any protocols it adopts.

Question 3

A type can adopt more than one protocol at a time.

Question 4

Default values can be specified for method parameters within a protocol’s definition.

Question 5

Protocols cannot require specific initializers to be implemented by conforming types.

Question 6

Protocols are types. You can use a protocol in many places where types are allowed.

Question 7

Delegation is a design pattern that enables a class or structure to hand off (or delegate) some of its responsibilities to an instance of another type.

Question 8

RestaurantsViewController is a class that has a superclass called UIViewController. RestaurantsViewController also adopts the protocols UITableViewDataSource and UITableViewDelegate. Which of the following is the correct way to declare the RestaurantsViewController class?

Question 9

A protocol cannot inherit from other protocols.

Question 10

The _________________ operator returns true if an instance conforms to a protocol and returns false if it does not. (See Checking for Protocol Conformance in The Swift Programming Language.)

conform to

Explanation / Answer

Answer: 1) Conform to

To provide an actual implementation of those requirements classes , structure, or enumeration adopt the protocal the protocol.

Answer : 2) before,

because without listing the superclass name it will not be able to adopt its protocal.

Answer: 3) true

multipe protocal can be adopted by using the commas.

Answer: 4) Flase

specific instance methods are required by the protocals and also type methods are reuired so that there can be implemented by conforming types.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote