Take your first look into the world of an App Developer.
Each of the 24 apps in this book is a small SwiftUI project you can open in Swift Playgrounds on your iPhone or iPad and run immediately. Try it out, then start making changes — see what happens when you tweak a number, swap a color, or comment out a line.
Every chapter includes exercises and challenges: things to try once you understand how the app works. There are over 150 exercises total. Some are quick, some will push you. They're where most of the learning happens.
No coding experience needed to get started.
What you'll need
- An iPhone or iPad running iOS 16 or later
- Swift Playgrounds (free from the App Store)
That's it. You can be running your first app within minutes of opening the book.
The apps
24 small SwiftUI projects, each one a standalone Playgrounds file. You don't need to read them in order — jump to whichever app looks interesting and start there.
The source code for every app is included. Read it, run it, break it, fix it.
Sample Apps
-
App 1
Hello World
The very first app — a Text view, a Button, and your first taste of @State.
-
App 2
Scoreboard
Keep score for two players with + and − buttons. @State for numbers, updated by taps.
-
App 3
Color Picker
Pick a color with iOS's built-in color wheel and fill the screen with it.
-
App 4
Edges
Fill the whole screen — including behind the safe area — and learn how SwiftUI lays out views.
-
App 5
Shapes
Draw circles, rectangles, and custom shapes — and style them with fills and strokes.
-
App 6
Move the Target
Drag a target around the screen with your finger using DragGesture.
-
App 7
Face Parts
Assemble a face from shapes and emoji using ZStack and offsets.
-
App 8
Roll the Dice
Shake or tap to roll a die — and learn how Swift generates random numbers.
-
App 9
John's Favorite Animals
A scrollable list of animals — your first data-driven view using List and a simple struct.
-
App 10
Super Color Picker
Build a color picker from scratch using three RGB sliders — no ColorPicker control this time.
-
App 11
Color Mixer
Pick two colors and blend them together — introduction to mixing color values.
-
App 12
Hold On Contest
Hold a button as long as you can — a timer-based contest that tracks your best time.
-
App 13
Pixel Paint
A pixel art editor built on a 2D array — tap cells to color them, change your color, make art.
-
App 14
Choose-Your-Own-Adventure
An interactive story where every tap is a choice — built around an enum-driven state machine.
-
App 15
Helpful Translations
A phrasebook app that shows useful phrases in multiple languages — list navigation and structured data.
-
App 16
Rock, Paper, Scissors
Play rock, paper, scissors against the phone — enum-based game logic, random computer moves.
-
App 17
Recipe Helper
A recipe display app with ingredients and steps — List sections and deeper data modeling.
-
App 18
Clock
Display the current time and watch it tick — Timer, Date formatting, and TimelineView.
-
App 19
Typing
A typing practice app — TextField, FocusState, and working with the keyboard in SwiftUI.
-
App 20
Not-so-Secret Messages
Encode and decode messages with a simple cipher — string manipulation with map() and character operations.
-
App 21
StopWatch
A working stopwatch with start, stop, and reset — Timer, elapsed time, and formatted display.
-
App 22
Sort Game
Put items in the right order — tap to swap, detect when the sequence is sorted.
-
App 23
Tortoise and Hare
Animate a race between two characters — Timer-driven progress, withAnimation, and offset.
-
App 24
Lights Out Game
The classic puzzle game — a 5×5 grid of lights where every tap toggles a cell and its neighbors.
-
App 25
Emoji Canvas
Bonus app — drag emoji around a free-form canvas, place them anywhere, and make a scene.