objective c memorization and learning help.

Discussion in 'Mac Programming' started by thymac, Sep 21, 2005.

  1. thymac macrumors member

    Sep 19, 2005
    i always wanted to lern objective c and cocoa because there are soem projects ive been interested in for quite sometime and they have been looking for new developers for some time. now my problem is just learning it and memorizing it. an example being the classes of objects. i just can't memorize it as many times as i read and write it down. im using a book (Learning Cocoa with Objective C 2nd Edition). im sure some of you developers have heard of it. do you have any suggestions on how to learn it i guess with out a book as much and in general how to memorize some of the functions of classes and objects. thanks thymac.
  2. plinden macrumors 68040


    Apr 8, 2004
    The only way to "memorize" is with experience. I still have five or so books I check things in and I've been programming for as long as I could handle a keyboard.

    Type in the program examples in your book, compile them, fix your typos, and repeat until the programs compile successfully. Run the compiled code and check if the result is as you expected. Debug, recompile and rerun until each example works exactly the way it should. Debugging might be a chore, but it's the most effective way of learning to program.

    By the time you have finished the book you'll have had a little experience - but you still won't be ready to call yourself a programmer. Try to think of a little project of your own. Don't be worried about having forgotten anything, that's going to happen. Use your book as a reference, and if that's not good enough, buy an Objective C reference book.

    So don't worry about having to memorize anything. When you're stuck, with an enough experience you'll remember having seen what you need and will know what to look up for the answer.
  3. HiRez macrumors 603


    Jan 6, 2004
    Western US
    As plinden said, it will come from experience and don't worry about trying to memorize every class. I constantly have the documentation window open (as well as reference books handy). I would recommend Scott Anguish's book Cocoa Programming as a good, comprehensive reference book. The only problem with it is that it's a bit out of date. I don't think it's been updated since 10.2, and that's a shame, so it includes nothing about Cocoa bindings, CoreImage, CoreData, or QTKit.

    There are some classes that are always useful and that you might want to make an attempt to learn first. For AppKit Classes, NSWindow, NSView, NSCell, NSControl, NSTableView, NSControl, NSImage, and NSImageRep are pretty important. From Foundation, you want to know NSObject, NSString, NSBundle, NSNumber, NSNotification and NSNotificationCenter, NSURL, NSTimer, NSData, and definitely all of the collection classes (NSArray, NSDictionary, etc.). The rest you will learn in time as you work through projects.

    Anyway, don't get intimidated, just keep coding.
  4. lexfuzo macrumors 6502

    Mar 15, 2005
    The heart of Europe
    As the others said, just keep on coding. You won't ever learn how to program by reading and writing classes.
    Work on your projects, read the docs, copy and paste, correct the errors.
    Some day it'll all be in your mind :)
  5. AlmostThere macrumors 6502a

    I have found AppKiDo quite useful as a quick reference. There are a few bugs but not enough to stop it being a useful browser. Doesn't take up much screen space, either.
  6. logicat2001 macrumors regular

    Apr 16, 2003
    Minneapolis, MN
    AppKiDo and Accessorizer are both indispensable while I code, as are the Anguish, etc. "Cocoa Programming" book, and OReilly's "Cocoa in a Nutshell" (which is a wonderful catalog of classes and methods.)

    With Cocoa, I'd recommend forgiving yourself the look-ups, they're inevitable. However, begin to notice the overall design of the frameworks. As I code now, after several years of practice, I can guess many methods because the Cocoa frameworks are (often) beautifully consistent. It's really fantastic, but something you (still) only acquire after consistent practice.

    When in doubt, refer to the docs.

  7. thymac thread starter macrumors member

    Sep 19, 2005
    thanks guys! the only thing im worriede about is wheni finish practicing multiple times with the books projects and etc, that when it comes time for me to make my own it will be hard because i didnt learn certain things.
  8. plinden macrumors 68040


    Apr 8, 2004
    The point we're trying to make is, the process of learning to program is more about discovering how to find out things for yourself, rather than memorizing stuff. If I don't know how to do something in Java, I read the Javadocs, look it up in a couple of reference books, or Google tutorials online.

    Programming has developed to the stage where almost everything has been done at least once already in some form.

    However, it's next to impossible to become a professional programmer in isolation. At work we review all code before it's checked into CVS, and less experienced programmers learn a lot from implementing the changes the code reviewer insists on - once they get over the crushed feeling they get on their code being severely criticized.
  9. Blackheart macrumors 6502a


    Mar 13, 2004

Share This Page