views:

609

answers:

9

Addition: Think its worth having a look at this again as a number of new books havve/are being released with updates to iOS4 and the inclusion of iPad programming.

Ok, I have read a number of posts regarding iPhone dev books, Cocoa and Objective-c. The general consensus seems to lead to one of 4 books.

  • Kochans Objective-C book.
  • Hilleglass Cocoa book.
  • The pragmatic programmers iPhone SDK development book.
  • And Beginning iPhone Development: Exploring the iPhone SDK by Dave Mark (Author), Jeff LaMarche (Author).

I've also added in the following:

  • IPhone Programming: The Big Nerd Ranch Guide

I'm looking for advice on which 2 to buy in order to get started. I'm looking firstly to get a better understanding of Objective-C. Which two books would compliment each other?

I have a background in Java, with NO Objective C experience and NO C or C++ experience either.

Firstly I'd like to get a good idea of the layout and structure of objects and certain data types - obviously it's worth keeping in mind a lot of this will be similar to that of Java. Concepts like pointers and garbage collection are completely new to me.

Thanks for your time.

A: 

At least, buy Hillegass's book. I haven't seen the iPhone one; the one for OS X is just fantastic.

I'm not sure about the second book to buy.

Yuji
Coming from just a Java background would this still be an ideal first choice?
Uncle
A: 

I prefer Learn Objective-C on the Mac than Kochan if you know c already.

Beginning iPhone 3 Development Exploring the iPhone SDK is a pretty good tutorial to iPhone development. Many others are good too.

yehnan
+1  A: 

Some of this will depend on your familiarity with Objective-C and it's API's.

Having said that, the Hilleglass Cocoa book and the Dave Mark book are both excellent (especially the Dave Mark book). I haven't read the Big Nerd Ranch book yet, but these two are 'must haves'. Dave Mark's book puts every other book on programming for the iPhone to shame.

In addition to those you probably want to take a hard look at 'Cocoa Design Patterns' by Erik Buck and 'Programming in Objective-C 2.0' by Stephen Kochan. The Cocoa API's are heavily influenced by Design Patterns and understanding how to use them as well as the language semantics will go a long way.

You may want to add a couple of specific books on some of the Cocoa API's as well, specifically Core Data and Core Animation. Understanding Core Data very well will change your coding abilities forever. The best book on that subject is the Pragmatic one by Marcus Zarra.

Having more then a couple of books is always a good thing... ;-)

RMatthews
Assume i have the most basic knowledge of ObjC - things like pointers, garbage collection and certain data types will be new to me. What would you recommend then?
Uncle
Don't get the Kochan book...however I felt much the same as you with a basic knowledge of Objective-C and I learned a lot from the Kochan book. Objective-C has a lot of subtle things that you can either learn from a book or through experience. I really think that Dave Mark's book is better than Erica Sadun's book.
RMatthews
+3  A: 

Programming in Objective-C 2.0 by Stephen Kochan for the foundation, The iPhone Developer's Cookbook by Erica Sadun for additional badassery. I learned more from Erica's book than any other source.

Typeoneerror
would these be suitable with no experience of c or c++?
Uncle
Kochan's book is quite rudimentary and Erica provides amazing library of sample code, so absolutely. I'd never done any c or c++ programming myself before iphone. I'm pretty fluent with objective-c now.
Typeoneerror
It's been a while but these are the actual two books I decided to buy - now it's time to get stuck into them
Uncle
+1  A: 

I've read through parts of the new Hillegass iPhone development book (not his older Cocoa book) at the bookstore, and my impression of it is that it's great, even for someone with not as much Mac development experience, but it works at a fast pace and is very terse. With prior Java experience, you're obviously a coder by background, so you may appreciate that, but he doesn't linger that much.

If you're only buying 2 books, I wouldn't buy a Cocoa/Mac one specifically. Stick with Objective-C and iPhone development in particular. While a lot of the Cocoa concepts exist in UIKit/Cocoa Touch on the iPhone, no point in learning things you can't apply on the iPhone. You can always pick up Mac development too once you've gotten the hang of Objective-C and iPhone development.

I'm reading Beginning iPhone Development right now and really like it. Most iPhone development books provide a good enough Objective-C intro that I wouldn't even recommend a dedicated book on it. You can learn the rest through online research, especially Apple docs. As a second book, I'd recommend Erica Sadun's iPhone Developer's Cookbook, since there's a lot of bang for your buck in the 1,000 page edition.

Also take a look at Craig Hockenberry's iPhone Development: The Missing Manual. He's the author of Twitterific, and his approach is to go through the entire design and development process for a souped up flashlight app, from start to the end. It covers design considerations that the other books don't, but to time, since they switch between a lot of smaller sample apps.

Joost Schuur
+2  A: 
  1. Kochan

    • C - primitives, structs, etc.
    • Objective-C - Foundation framework
    • Compiler - pre-processor, macros, directives
  2. BNR iPhone Programming Guide

    • Shares material from the Cocoa Book on core concepts like Objects and Delegation etc.
    • Covers Navigation, TableViews, Tab Bars which are critical to iPhone development.

In both books, every line of code in the sample projects are listed and explained in detail allowing you to type out the code (follow the bouncing ball anyone?), make mistakes, then correct them, which is critical to the learning process.

falconcreek
A: 

Hilleglass all the way.

Leibowitzn
+1  A: 

It really depends on your learning habit.

  • If you are the learn-by-examples type, go for:

    • Beginning iPhone Development by Dave Mark (Author), Jeff LaMarche
    • The iPhone Developer's Cookbook by Erica Sadun

    the above two will get you start on some real world projects fast.

  • If you are the read-all-before-hands-on type, go for:

    • Apple docs, and save yourself a few bucks

I found it a bit strange to start a question with a criteria of 2 books. Every book mentioned in your list is money well spent. You won't regret to buy them all. Besides, the Stanford course videos is also good for beginners, not a book though.

ohho
the idea was to get up to speed on objective-c before diving into the iphone sdk thats why i suggested the 2 books. thanks for telling me about the Stanford courses this seems like a pretty good idea!
Uncle
A: 

If you do not have C or Objective-C background I would suggest to start with "Learn C on the Mac"(Mark) followed by "Learn Objective-C on the Mac"(Dalrymple,Knaster) and then "Beginning iPhone 3 Development"(Mark,LaMarche), all by Apress. If you really want to nail it down to two books leave off "Learn C", because you might only really need C, when you start diving deeper into Core Foundation.

I do not know Kochans Objective-C book, so I can't compare, but coming from a different language you should really have a book about only Objective-C. The introductionary chapters in some iPhone books may be sufficient to get you starting, but to advance you'll need to know about all the possibilities of the language.

I personally would not suggest "The iPhone Developer's Cookbook" by Erica Sadun to learn coding for iPhone, although I use it as quick reference quite sometimes.

tonklon