Starting with the most basic topics related to Swift 6, learning advanced topics, and keeping small interactive examples together in one place.
This repository contains playgrounds and sample iOS applications about the basics of programming with Swift 6.
You can develop applications for desktop, mobile, tablet, TV, smart watches, servers, embedded devices, and WebAssembly with Swift.
- Hello World
- Variables
- Var vs Let
- String Methods 1
- String Methods 2
- Int, Float and Double
- Boolean
- Arrays
- Dictionaries
- While Loop
- For Loop
- If, Else
- Switch Case
- Functions
- Classes
- Optionals
- Sets
- Enumerations
- Methods
- Structures
- Type Casting
- Convert Data Types
- Calculator
- Find My Age
- Prime Number
- How Many Fingers
- Find Cats Age
- Classes & Objects
- Optionals Masterclass
- For Loops
- While Loops
- String Manipulating
- Open any
.playgrounddirectory in Xcode to run the lesson interactively. - Open
HowManyFingers/HowManyFingers.xcodeprojorCatYearsFind/CatYearsFind.xcodeprojin Xcode to run the sample iOS apps. - The playground examples use
Foundationinstead ofUIKit, so the language-only samples can also be checked by the Swift command-line tool.
- The Swift Programming Language
- Install Swift
- Swift.org Documentation
- Swift Package Manager
- Swift Evolution
If this project helps you reduce development time, you can give me a cup of coffee. β
MIT License
Copyright (c) 2026 Halil OZEL
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

