I have spent most of my coding career developing software with the .Net stack. I was either developing WinForms apps or ASP.Net websites. Over the past few years, I have been dabbling with Objective-C for Desktop Intercom. I have made it a goal of mine to do more development. Since I have alway been an Apple fanboy, I have decided to learn the Swift language.
To start, I have been reading the Swift 4.2 Programming Language book. It is a very interesting read. For many years, I have been coding in C#. I have found C# to be a very easy language to get started in. Swift looks like it is even easier to get started with! It is made even easier due to the inclusion of Swift Playgrounds. It only takes a couple of lines of code to write Hello, world.
// Hello, World. import Swift. print("Hello, World!").
As I am getting into the language, I am happy to be surprised by some interesting constructs such as the defining a range like this:
let range = ...5
One thing I do not like is the auto assumption of types based on the assigned data.
Let val = “string”
Maybe I am old school but I really prefer having the type of a variable specified when the variable is created. I feel that it makes the code easier to read.
Let Val:String = “string”
I still have a long way to go but so far I am enjoying learning the language and I even bet that I will get used to the assumptions of the types. 😀