Videos 12
Video: Enumerations
An enumeration defines a common type for a group of related values and enables you to work with those values in a type-safe way within your code.
If you are familiar with C, you will know that C enumerations assign related names to a set of integer values. Enumerations in Swift are much more flexible, and do not have to provide a value for each member of the enumeration. If a value (known as a “raw” value) is provided for each enumeration member, the value can be a string, a character, or a value of any integer or floating-point type.
Alternatively, enumeration members can specify associated values of any type to be stored along with each different member value, much as unions or variants do in other languages. You can define a common set of related members as part of one enumeration, each of which has a different set of values of appropriate types associated with it.
This video was developed by Skip Wilson. You can follow him on Twitter (@SkipAllMighty).
Video: Closures
Closures are self-contained blocks of functionality that can be passed around and used in your code. Closures in Swift are similar to blocks in C and Objective-C and to lambdas in other programming languages.
Closures can capture and store references to any constants and variables from the context in which they are defined. This is known as closing over those constants and variables, hence the name “closures”. Swift handles all of the memory management of capturing for you.
This video was developed by Skip Wilson. You can follow him on Twitter (@SkipAllMighty).
Video: Making A Game
In this tutorial you’ll make a simple tic-tac-toe game using Swift. See if you can beat the computer in this classic game you played as a kid.
Source code: https://github.com/skipallmighty/Swif…
Algorithm details: http://en.wikipedia.org/wiki/Tic-tac-…
We skip forks and opposite corners of algorithm.
Assets here: http://imgur.com/a/V9xpk
This video was developed by Skip Wilson. You can follow him on Twitter (@SkipAllMighty).
Video: Classes
Classes are general-purpose, flexible constructs that become the building blocks of your program’s code. You define properties and methods to add functionality to your classes by using exactly the same syntax as for constants, variables, and functions.
Unlike other programming languages, Swift does not require you to create separate interface and implementation files for custom classes and structures. In Swift, you define a classin a single file, and the external interface to that class or structure is automatically made available for other code to use.
This video was developed by Skip Wilson. You can follow him on Twitter (@SkipAllMighty).
Video: Structures
Structures are general-purpose, flexible constructs that become the building blocks of your program’s code. You define properties and methods to add functionality to your structures by using exactly the same syntax as for constants, variables, and functions.
Unlike other programming languages, Swift does not require you to create separate interface and implementation files for custom structures. In Swift, you define a structure in a single file, and the external interface to that structure is automatically made available for other code to use.
This video was developed by Skip Wilson. You can follow him on Twitter (@SkipAllMighty).