You read it right. If you are using iOS8, UISplitViewController indeed behaves as if it’s a UINavigationController on iPhone. Obviously it means that UISplitViewController is now supported for iPhones as well. This is a small but important part of the bigger picture of Universal Storyboards and Adaptive UI starting from iOS8.
A few days back I was trying to create a simple iOS app to compete in one of the contest at Topcoder. I needed a Table View to show initial menu, then one of the menus had submenus so needed second Table View to show that. I needed a couple of Detail Views which should open when clicked on any of the menu items.
I have used enums, structs and classes in other languages before, but never thought that I will ever be comparing them,1 as they always seemed to be completely different programming concepts in other languages. Well Swift is different, it has supercharged enums and structs so much so that it may seem overwhelming and outright confusing.
Ok, brace yourself. Here it comes - Both enums and structs can have properties and methods like classes.
Ok so finally we see some real Swift code for the first time on this blog. Yay!! As I mentioned in my last post, my solution 1 for the Topcoder $100 Playground challenge is given below. It helped me to get started with some Swift syntax and get a bit comfortable using playground feature of Swift. Don’t worry about so many lines. Most of it is comments. Comments basically are instructions for participants on what needs to be done. Solution to the problem follows the comment.
So as I mentioned in my last post I was trying to find something to do in Swift. I thought, maybe I should work on some simple, dummy apps to hone my skills. I was considering a few ideas, but then I got a mail from Topcoder announcing their GetSwifter series. It basically is a series of development challenges in Swift. They have decided to distribute $500,000 as prizes.