Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

iOS

Wanting to begin learning iOS development, should I start with Objective C or SWIFT?

I understand there are very few apps running SWIFT but if iOS is migrating to it should I just skip OBJ-C and learn SWIFT instead?

Thanks for the replies!

6 Answers

My personal opinion is start with Swift, because it's a lot easier to pick up. Objective-C takes a while to learn, and with it slowly being considered outdated, one should not waste valuable time trying to completely master it before Swift.

Build a solid understanding of iOS development in Swift, then build on your knowledge, by learning Objective-C. I say this because there's a lot more open source code, and tutorials for Objective-C, then there is for Swift at the moment. This will allow you to learn the library and things like Interface Builder. Though, Apple has done a great job of updating the library for Swift. If you grasp a good understanding of Swift, you can look at Objective-C tutorials, and consider how you may be able to the same thing in Swift.

The important thing to remember is that Swift, in a sense, is nothing but a more modern way to write Objective-C. Learning both will help because, where Swift has yet to develop, you can Objective-C, and vice versa.

I would say go through the Swift Basics, Functions and Optionals, then the Simple iPhone App with Swift. After that, switch over to the Objective-C, then Build a Simple App in Objective C.

Ultimately, it's a matter of time, and preference; not which one should I learn first.

However, if you have the and patience, learning them side by side would be great. This is pretty much what I've been doing.

Also, be sure to download Apple's free eBook for Swift from the apple store.

Hi Austin,

I would recommend you learn the basics of Objective-C first as there are still some areas of Swift that will be fuzzy if you don't have a basic understanding of Objective-C, below is the order I would recommend you go about learning iOS development.

I'm watching this thread to see what others say. I had the thought to switch today as well.

I know it's not the answer you're looking for, but I started the Objective-C track about a month ago. (Before the Swift track was available) I'm not even half way finished but it's a great introductory course into programming for the iPhone. The xcode in the video is outdated by a few years but it's still a great way to understand the logic behind the code, file structure, and the history of programming in C. If Swift is the way to go, at least I have a general understanding going into that track.

Do you know anything about programming e.g. variables, constants or classes?

if no, then start with swift otherwise start with obj-c

Obj-C is more like C and C++ and is a good way to learn iOS because most of the libraries are still in obj-C

I'll throw this question back to you: Did you learn JavaScript or jQuery first? I would equate the two situations. Were you able to understand the language by learning it's shortcuts first and then taking your time to learn how to do it by hand, or do you need to understand how things work before learning how to combine functions/features in a language?

Objective-C / Xcode still has a lot of drag-and-drop and editing attributes through input boxes. It's not required to do it all by hand in the editor.

I also thought of the two to be similar, and was going to put it in my response, but it doesn't work.

Swift is not a library for Objective-C. Swift is a standalone language, that uses the same Frameworks and libraries as Objective-C.

Thanks for the clarification. I haven't looked at Swift yet (other than a quick glance at Apple's marketing material) so I didn't know the difference.

Swift is not a library for Objective-C. Swift is a standalone language, that uses the same Frameworks and libraries as Objective-C.

This is the reason it's better to learn Objective-C first as without basic knowledge of Foundation and UIKit you'll be more or less lost.

Would someone not be able to gain that same knowledge in Swift if they chose to? I'm not sure if you haven't viewed the documentation in the iOS Developer Library lately, but all classes and methods in the documentation have examples for implementing it within Objective-C and Swift. For example, UIColor. You're able to toggle between either language, or both.

I haven't started the SWIFT classes here, but I will soon.

I have however read half of the Swift E-book provided by Apple on my ipad and its really different than what I have learned so far in Objective-C. The E-book is really nice and easy to read. I suggest reading alongside classes on treehouse. Being a beginner in both Objective-C and Swift, I find Swift syntax a lot more natural and easier to learn.