General Question

mcspring's avatar

How could I learn programming?

Asked by mcspring (29points) December 22nd, 2010

I wanna learnning objective-c, but i have no mac machine.

Observing members: 0 Composing members: 0

11 Answers

mithical's avatar

Classes is the best option. I’m sure there’s some available where you live, if not, the nearest big town (like what I have to do!)

If not, there are tons of helpful guides online to help you get started.

Apple has a great guide for that here.

As to the Mac question, I would recommend start saving for one and start looking for some deals online, there’s always someone selling some in mint condition and cheap!

koanhead's avatar

I agree with @mithical that taking one or more classes is the best way. I never did, and I’m a crap programmer ;^/
However, it is possible to do it on your own. Keep in mind that learning to program is a separate skill from learning a particular language. If you eventually want to become an Objective-C programmer then you might want to start with a relatively easy Object-Oriented language like Python, which is available for any computer for free. Once you become comfortable with basic programming skills you might change to a c++ compiler (or C# perhaps, or some other similar language. I don’t know Obj-C but I’m guessing it’s yet another OO version of C.)

NanoBiscuit's avatar

I agree with @koanhead and @mithical that classes are the way to go for getting into the meat of programming.

And, Microsoft has free downloads of the Visual Studio 2008 Express with all or separate C#, C++, VB, and Web Developer products here: Visual Studio Express 2008.

C++ would be the closest you would get, but the syntax, structure, formatting, and applications should be similar. It would be the interface, or global definition, between MAC and MS that would require update to move over.

And, there are a number of online tutorials in the local and online help for building sample applications from and for drilling into the code to see what it’s doing. It also has syntax checking and debugging capability to step into the code as it is executed.

LostInParadise's avatar

The various types of C are not that much different from one another. If you learn one, it will greatly help in transitioning to another. Taking a class is helpful, but this is something that you could learn on your own with a book or a tutorial. The great thing about programming is that you can test yourself by writing small programs. There is a lot that you will learn simply from compilation errors.

gorillapaws's avatar

I’m a self-taught hobbyist Mac programmer. It takes a lot of time and hard work to get there, but it’s doable. You basically have 2 approaches to take when you’re just starting out without a Mac.

If you’re the type that likes to know where every little detail goes and how it all fits together, then start with C. Objective-C is a strict superset of C (which means all C is valid Objective-C code, but not the other way around), so knowing C and feeling comfortable with managing memory, typing, pointers, data structures, etc will all be critical to writing Mac software.

If you’re the type that likes to ease into things, and want a language that hides some of the complexity for you while you’re getting started then I would suggest Python. You’ll eventually need to learn all of the nasty details of pointers and memory management when you’re working with Mac software development, but you may want to “take things on faith” with Python when you’re just getting started. Python is an excellent language, and will be helpful to you later on even after you learn to write Mac software.

If you do go the Python route, then later you’ll still need to learn C. Up until this point, it’s not necessary to own a Mac. It’s going to take you a while to get to the point where you feel comfortable writing simple C command-line programs. Hopefully by this point, you’ve saved up enough to buy your first Mac (get something that can run the latest version of OSX which will probably be 10.7 by the time this is an issue). A refurbished Mac Mini is a great way to get your foot in the door cheaply, and allows you to re-use your exiting monitor, keyboard and mouse that you have on your pc, a used/refurbished iMac is another good starting place, but will cost you more.

Now you’re ready to learn Objective-C. Technically you can write Objective-C on a PC with GNUStep, but you’ll be missing some important things that are Apple-specific. When you’re ready to learn Objective-C the book you need to get is Stephen Kochan’s Programming in Objective-C 2.0; it’s excellent and will be useful as a reference later on. The author wrote a book on C as well, which might be a good starting place.

Once you’ve finished learning the language of Objective-C, you’ll be ready to learn Apple’s Cocoa framework. Cocoa is made of both the foundation framework (which Kochan covers the basics of in the 2nd part of his book) and App Kit. Once you’ve gotten to the point where you can comfortably write simple (and even moderately complex) command line Objective-C programs, it’s time to move on to learning Cocoa. The book you need for this is Cocoa Programming for Mac OS X by Aaron Hillegass. It’s excellent, but won’t make any sense if you’re trying to skip ahead too quickly. Also be sure to consult Apple’s documentation if you run into problems, or areas that you can’t grok from the book.

Good luck, and be prepared to invest a lot of time and energy.

Response moderated
Response moderated (Spam)
Response moderated
LostInParadise's avatar

I second @gorillapaws suggestion of starting with Python. It is now the most widely taught language. Python is fairly easy to learn, and it has enough in common with the various C languages that you will be able to carry over much that you learn from Python. There is a lot of documentation and courses on the Web.

gorillapaws's avatar

Seeing as how this post is a decade old and was necroed by a spammer, I’ll just mention for posterity that Swift is the way to go for learning MacOS programming in 2021. Python is a great first language, but Swift is a better language in many respects, and certainly the best choice to start if the end-goal is MacOS Cocoa development.

Answer this question

Login

or

Join

to answer.

This question is in the General Section. Responses must be helpful and on-topic.

Your answer will be saved while you login or join.

Have a question? Ask Fluther!

What do you know more about?
or
Knowledge Networking @ Fluther