Workshop
Quiz
ARC stands for what?
- Automatic Reference Counting
- Aggregated Recall Counts
- Automated Reference Cycling
- Apple Really Cares
The class files that you create for your applications will have which file extension?
- .swift
- .m
- .c
- .swf
Variables and methods that may return nil are known as what?
- Uncontrolled
- Controlled
- Optional
- Implicit
Declaring a variable with a ! after the type definition makes it what?
- Unwrapped
- Optional
- Explicitly unwrapped
- Implicitly unwrapped
Stringing together method calls and variable properties is known as which of the following?
- Spanning
- Bridging
- Chaining
- Declaring
A variable that is defined outside of a method and that can be accessed from other classes is called what?
- Constant
- Instance variable
- Implicitly unwrapped variable
- Variable property
To declare a constant versus a variable, you replace the var keyword with which of the following?
- set
- get
- let
- constant
Variable types that can store multiple different values are known (in general) as what?
- Collections
- Sets
- Structs
- Aggregates
At the time iOS 8 was released, Swift had been available to the public for how many years?
- 0
- 1
- 2
- 3
Swift classes are defined using how many files?
- 1
- 2
- 3
- 4
Answers
- A. ARC stands for Automatic Reference Counting and is the process Apple’s development tools use to determine whether an object can be freed from memory.
- A. Class files developed in swift should include the .swift file extension.
- C. A variable or method that returns nil (no value) is said to be optional.
- D. Adding an exclamation point (!) after a variable’s type definition sets that variable to be implicitly unwrapped.
- C. Swift methods and variable properties can be strung together in a process called chaining.
- D. Variable properties are declared outside of methods and can be accessed and used by other classes.
- C. The let keyword is used to declare a constant.
- A. Collections, including Arrays and Dictionarys, are used to store multiple pieces of data.
- A. Swift and iOS 8 were released to the public at exactly the same time.
- B. A Swift class requires exactly one file for its implementation.