When Apple announced Swift at WWDC 2014 my jaw hit the floor. Along with everyone else I had no way to guess that Apple was preparing such a massive announcement. Not only did they announce a whole new language that was ready to start being developed on, but one that was backwards compatible with the entirity of the Cocoa Touch framework, written in an entirely different language (Objective-C).
I've had my fair share of experiences writing an iOS application last year when I released my first and currently only iOS app called Jot. Learning Objective-C and Cocoa Touch was a lot of fun however after a while Objective-C got to be a little long in the tooth. It's not a bad language, however it is very verbose. That's as much a fault of Cocoa Touch's naming conventions but also due to Objective-C's eager use of brackets
With Swift comes an entirely new syntax, one designed from the ground up to be as developer friendly as possible. And that makes this developer quite happy. Optional (and discouraged) semi-colons? Dot access of properties and methods by default? A trailing closure syntax to reduce closure confusion? Check, check, and check. Color me pleased.
I've started learning Swift by reading as much as I can. I've read all of Apple's provided material along with every tutorial on the internet I've come across, reading myself cross-eyed. I finally managed to coerce myself to open up Xcode and start coding and realized that reading is not even remotely close to writing.
With Xcode open I just stared at the screen, unsure how to even start. I remembered reading so many things about how to make an application, seeing so many boilerplate code examples of what an application looked like, but when I sat down to create my own my mind went blank.
As it is said, it is best to learn by doing.
So that's what I've decided I need to do. I need to start writing some Swift code.
Luckily I came across a contest online titled Summer of Swift. Billing itself as An Ephemeral Contest to Learn Swift by Doing I could not imagine a better way for me to get off my ass and start learning by doing. There is no true idea of 'winning' this contest, as the prize at the end is a better understanding and knowledge of how to write Swift applications. That's the goal of the contest. To make it exciting to learn Swift!
I've thrown my entry into the mix and am awaiting approval.
In the meantime I've decided to develop in the open. Follow along with my progress on my open source repo Bapit. It's where you'll see my work appear. I'm planning on making a simple Swift game involving a ball and tapping. We'll see how that evolves as the summer goes on.
If you're looking to learn Swift then just open up Xcode and start coding! It's never too late to start. Don't get hung up on doing things right, just start doing anything. Also let me know if you find any excellent Swift tutorials. Always on the prowl for those.