w3resource

Swift Programming Exercises, Practice, Solution

Swift Programming Exercises with solution

Swift is a powerful general-purpose, multi-paradigm, compiled programming language developed by Apple Inc. for iOS, macOS, watchOS, tvOS, and Linux. Writing Swift code is interactive and fun and Swift includes modern features developers love. Swift is designed to work with Apple's Cocoa and Cocoa Touch frameworks and the large body of existing Objective-C (ObjC) code written for Apple products.

The best way we learn anything is by practice and exercise questions. We have started this section for those (beginner to intermediate) who are familiar with Swift language. Exercises are designed to enhance your ability to write well-structured Swift programs. Hope, these exercises help you to improve your Swift programming skills. Currently following sections are available, we are working hard to add more exercises. Happy Coding!

List of Swift Exercises:

Popularity of Programming Language
Worldwide, Dec 2021 compared to a year ago:

`
Rank Change Language Share Trend
1 Python 30.21 % -0.5 %
2 Java 17.82 % +1.3 %
3 Javascript 9.16 % +0.6 %
4 C# 7.53 % +1.0%
5 C/C++ 6.82 % +0.6 %
6 PHP 5.84 % -0.2 %
7 R 3.81 % -0.0 %
8 up arrow Swift 2.03 % -0.2 %
9 down arrow Objective-C 2.02 % -1.6 %
10 up arrow Matlab 1.73 % -0.1 %
11 down arrow TypeScript1.63% -0.2 %
12 up arrow Go 1.52 % +0.2 %
13 down arrow Kotlin 1.44 % -0.2 %
14 VBA 1.27 % +0.1 %
15 up arrow Rust 0.94 % -0.2 %
16 down arrow Ruby 0.89 % -0.2 %
17 up arrow Ada 0.86 % +0.2 %
18 Scala 0.63 % -0.1 %
19 up arrow Dart 0.61 % +0.0 %
20 up arrow Abap 0.55 % +0.1 %
21 down arrow Visual Basic 0.53 % -0.2%
22 up arrow Groovy 0.48 % +0.1 %
23 down arrow Lua 0.47 % -0.2 %
24 Julia 0.36 % -0.0 %
25 down arrow Perl 0.3 % -0.2 %
26 up arrow Haskell 0.28 % -0.0 %
27 down arrow Cobol 0.26 % -0.1 %

Source : https://pypl.github.io/PYPL.html

TIOBE Index for November 2021

Nov 2021 Nov 2020 Change Programming Language Ratings Change
1 2 up arrow Python 11.77% -0.35%
2 1 down arrow C 10.72% -5.49%
3 3 Java 10.72% -0.96%
4 4 C++ 8.28% +0.69%
5 5 C# 6.06% +1.39%
6 6 Visual Basic 5.72% +1.72%
7 7 JavaScript 2.66% +0.63%
8 16 up arrow Assembly language 2.52% +1.35%
9 10 up arrow SQL 2.11% +0.58%
10 8 down arrow PHP 1.81% +0.02%
11 21 up arrow Classic Visual Basic 1.56% +0.83%
12 11 down arrow Groovy 1.51% -0.00%
13 15 up arrow Ruby 1.43% +0.22%
14 14 down arrow Swift 1.43% +0.08%
15 9 down arrow R 1.28% -0.36%
16 12 down arrow Perl 1.22% -0.29%
17 18 up arrow Delphi/Object Pascal 1.22% +0.36%
18 13 down arrow Go 1.21% -0.16%
19 34 up arrow Fortan 1.19% +0.79%
20 17 down arrow MATLAB 1.17% +0.07%

Source : https://www.tiobe.com/tiobe-index/

List of Exercises with Solutions :