App Development with Swift study plan
App Development with Swift · Give each week a clear focus.
8 weeks · About 7 hours per week
Swift Language Fundamentals & Control Flow, Functions, and Closures
Declare constants and variables across Int, Double, String, Bool, and tuples, writing down the inferred type before compiling each line.
Write branching logic with if, guard, and switch, including range matching and where clauses, and rewrite two if-chains as switches.
Implement for-in, while, and repeat-while loops that build and filter a 20-item in-memory dataset without using higher-order functions.
Trace and repair 10 deliberately broken snippets covering integer overflow, string interpolation, and operator precedence.
Your checkpoint
A Swift playground plus a command-line target containing 20 XCTest assertions that all pass, each one annotated with the single language rule it proves.
Control Flow, Functions, and Closures
Write functions with argument labels, default parameters, variadic parameters, and inout parameters, then justify each choice in a comment.
Convert three named functions into closure expressions using shorthand argument names and trailing-closure syntax.
Distinguish escaping from non-escaping closures by storing one for later execution and proving capture behaviour with a test.
Implement map, filter, reduce, compactMap, and sorted over a string array, replacing five hand-written loops.
Explain capture lists and strong reference cycles in a closure with a two-object demo that you run and observe.
Your checkpoint
A TextStats command-line package exposing 8 functions built on closures and higher-order functions, with 25 passing XCTest cases and a README mapping each function to the closure concept it demonstrates.
Data Modeling with Structures, Classes, Enumerations, and Protocols
Build five structs and three classes modelling a library lending system, choosing value or reference semantics deliberately for each type.
Implement designated, convenience, and failable initializers, and justify in a comment why each initializer exists.
Demonstrate copy-on-assignment for structs and shared mutation for classes with paired tests that would fail under the wrong semantics.
Add computed properties, property observers, and lazy properties to the model and test each one's behaviour.
Diagram ARC ownership for the class graph, then break one retain cycle with weak and confirm the deinit fires.
Your checkpoint
A modelling package with 8 types and 30 passing tests, plus a text-form object graph labelling every strong, weak, and unowned reference.
Data Modeling with Structures, Classes, Enumerations, and Protocols & Swift Language Fundamentals
Replace every stringly-typed constant with an enum using raw values, associated values, and CaseIterable.
Define three protocols, conform existing types to them, and add default implementations in protocol extensions.
Write one generic function constrained to a protocol and refactor two duplicated concrete functions into it.
Drive a multi-step workflow from an enum with associated values and switch over it exhaustively.
Your checkpoint
A refactored model where every state is an enum and every shared behaviour is a protocol, with 35 passing tests and no duplicated concrete implementations remaining.
Collections, Optionals, and Error Handling
Select between Array, Set, and Dictionary for five stated scenarios and record the Big-O justification for each in a comment.
Sort, group, and deduplicate a 500-item dataset using only higher-order functions.
Rewrite 10 forced-unwrap sites as optional binding, optional chaining, or nil-coalescing, and note what each rewrite makes safer.
Write tests proving collection copy semantics and that index access stays in bounds after mutation.
Your checkpoint
A data-processing command-line tool that ingests a bundled CSV, groups and ranks entries, and prints a report, covered by 20 passing tests.
Collections, Optionals, and Error Handling
Define a custom Error enum with four cases and throw it from a validating initializer.
Wrap throwing calls in do/catch with case-specific recovery, and use defer to guarantee cleanup.
Convert a callback-plus-optional-return API into one returning Result, then compare the two call sites side by side.
Apply guard-let at function boundaries and demonstrate early exit for each documented failure mode.
Your checkpoint
A parsing pipeline that validates, throws, recovers, and logs, backed by 25 tests of which at least 8 exercise failure paths.
User Interfaces and App Architecture
Compose three screens (list, detail, form) with NavigationStack, passing data through initializers instead of globals.
Manage state with @State, @Binding, and an observable model type, documenting which object owns the source of truth.
Extract view models so the view files contain no business logic, and unit-test each view model in isolation.
Render loading, empty, and error states for the list screen from a single state enum.
Your checkpoint
A runnable three-screen app with a tested view-model layer and a written description of each screen's state flow and data ownership.
User Interfaces and App Architecture & Collections, Optionals, and Error Handling
Apply MVVM with dependency injection through protocol-typed constructor parameters, then swap in a fake service during tests.
Write unit tests for the view models and one UI test covering the app's primary navigation flow.
Refactor one screen to remove a singleton and record how many previously untestable paths became testable.
Complete two timed 50-question mixed practice sets and log every error by domain.
Your checkpoint
A finished app repository with an architecture README, 40+ passing tests, and an error log showing every domain at or above 80% on the final practice set.
Milestones
Week 2: From a blank file, write and run a function that takes a closure, mutates captured state, and passes a test for that behaviour, in under 10 minutes with no reference material.
Week 4: Score 80% or higher on a timed 30-question set over domains 1-3, and give an unscripted five-minute walkthrough of value versus reference semantics with a live code demo.
Week 6: Score 80% or higher on a timed 30-question set over domains 1-4; every missed item becomes a flashcard paired with a compiling snippet that proves the correction.
Week 8: Score 85% or higher on a full mixed practice exam with no individual domain below 75%, and produce a simulator build of the three-screen app.