Getting started
Constants, Variables and Data Types
• Introduction to playground
• Constants and variables
• Introduction to Data Types
• Introduction to String Data Type
• Introduction to Int data Type
• Introduction to Float and Double Type
• Introduction to Boolean Data Type
• String interpolation
• String interpolation continued...
• Good naming conventions to follow
Swift Operators
• Arithmetic operators
• Integer division and possible errors
• Remainder operator
• Compound assignment operators
• Comparison operator
• Comparison operator - checking for equality
• NOT operator
• How to find out the data types of variables
• Type Casting
• Problem Solution 1 - Swap variables
• Problem Solution 2 - Area and perimeter
• Problem Solution 3 - Calculate Percentage
• Problem Solution 4 - Last digits of a number
If Statements
• Introduction to If statements
• Else branch
• Nested if statement
• Else...if statements
• Problem and Solution: Maximum of two numbers
• Problem and Solution: Even or odd number
• Problem and Solution: Divisibilty calculations
• Logical AND operator
• Logical OR operator
• Problem Solution: Class marks
• Problem Solution: Divisibility revisited
• Ternary conditional operator
Switch Statements
• Switch statements
• Switch case - matching multiple values
• Switch range matching
• Switch break statement
• Fallthrough statement
Arrays
• Introduction to Swift Array
• Getting multiple values using closed range
• Array type and Any type
• Merging two arrays
• Adding values to existing array
• Removing values from arrays
• Modifying values in arrays
• Mutable and immutable array
• Copying value from one array to another - reference and value types
Dictionaries
• Introduction to Dictionary
• Retrieving values from a dictionary
• Adding a new key-value pair to a dictionary
• Updating value in a dictionary
• Removing items from dictionary
• Other dictionary methods
For Loop, While Loop and Repeat While Loop
• Introduction to For Loop
• Using value of "i" in a loop and the underscore variable
• Looping through arrays
• Looping over dictionaries
• Problem and Solution: Maximum value in an array
• Problem and Solution: Separate numbers into odd and even
• Problem and Solution: Sum the content of an array
• Problem and Solution: Reversed array
• Inner loops
• Break statement
• Continue statement
• Introduction to While Loop
• Beware of an infinite loop
• Repeat while loop
• Repeat while loop example
• Problem and Solution: Separate numbers to array - while loop example
Swift Functions
• Introduction to Function
• Function parameters
• Multiple parameters of a function
• Returning values from functions
• Calling a function from another function
• Parameter as a let constant
Optionals
• Introduction to Optionals
• Introduction to Optionals contd...
• Returning nil from a function
• How to work with optional values
• Unwrapping optional values
• Force unwrap optional types
• Implicitly unwrapped Optionals
• Nil coalescing operator
• Multiple optional binding - unwrapping multiple optionals
• Optional Chaining
• Variable scopes