When working with Swift generics, note the variable T isn’t a special reserved word in Swift but works as a regular declared variable. As a result, the value of T could easily be replaced with any letter of choice, including U, W or Y.

Conditional logic or statements used to discontinue execution of a recursive algorithm.

When learning the basics of Big O Notation for a technical interview, start by reviewing the the performance runtimes of “core” algorithms. By understanding these common functions, you’ll eventually be able to recognize the same patterns in your own code. These include:

  • O(1) - Stacks, Hash Tables

  • O(n) - Linear Search

  • O(n2) - Bubble Sort

  • O(log n) - Binary Search, Binary Search Trees (BST’s)

  • O(n log n) - Quicksort

A situation where a programmer writes a solution without consideration of its algorithmic efficiency. In some cases, brute force solutions lack sophistication and perform operations in “linear time” - O(n) or greater.

Managed by the code complier, the call stack tracks functions executed by a program. 

A term used when evaluating algorithms that always perform at a “constant” speed, regardless of their input size. Common algorithms that perform constant time operations include Stacks and Hash Tables.

A common iOS design pattern where a class “hands off” partial responsibility for its function to another class.

The process of deconstructing a single, complex system into a series of sub-systems. In computer science, “Divide and Conquer” strategies can often be found in search/sorting algorithms, graph theory and dynamic programming. 

A common programming technique where logic is applied by “looping or iterating” through a list or collection.

A coding technique of applying storage and reuse to improve overall algorithmic efficiency.

When programming, a memory leak occurs when an application fails to reclaim the portion of a memory used by a variable. In development terms, we often say that portion of memory is unrecoverable or has “leaked”. Prior to the concept of automatic reference counting (ARC), memory leaks were common in Objective-C based applications.

In Swift, a function keyword used to indicate when a class instance (self) is modified.

In programming, null pointer exceptions occur when a portion of deallocated memory is referenced in a program or application - usually at runtime. Null exceptions are common in other non-Swift languages such as Objective-C, but can still occur in Swift-based programs through the use of implicit unwrapped optionals.

Exclusive to Swift, Optionals identify a variable being able to hold a nil value. Swift variables that are permitted to hold a nil value are identified with a ? or ! character.

Exclusive to Swift programming, the process of managing program actions and functionality using protocols. 

When evaluating algorithmic performance, functions are often analyzed based on their speed of operation (e.g. time) as well as how much storage “space” they may occupy.

In Swift, the technique to extend a type with additional functionality. Extensions can be declared on native types such as String or Int, as well as any custom type. 

A popular method of describing system processes through the use of specific diagrams and notation.

Code designed to test other code or software components that often lack an end-user interface.