Slashdot Mirror


Stanford Offers Cocoa Class

An anonymous reader writes "Back in the early 90's Stanford University offered a class on Objective-C for students interested in writing applications for NeXTSTEP. After a long hiatus it appears that class will be offered again as CS193E, 'Object-oriented User Interface Programming.' It will be covering the Apple development tools, Objective-C, Foundation and AppKit, and Quartz. Any other schools out there planning or already offering Objective-C courses?"

35 of 91 comments (clear)

  1. textbooks? by TomSawyer · · Score: 2, Interesting

    I wonder if they'll be using O'Reilly's ADC blessed books for texts.

    --
    If you disagree then it must be overrated, redundant or trolling.
  2. Strange by nepheles · · Score: 5, Insightful

    It seems strange that Objective-C has failed to attract the popularity of C++, given that it seems (to me at least) by far the more elegant of the two. It implements object-oriented programming in a much cleaner way than C++, and still loses none of the power of C. What Java should have been, really

    --
    ((lambda x ((x))) (lambda x ((x))))
    1. Re:Strange by quandrum · · Score: 4, Funny

      It's "too different" from C. I hear this all the time when talking about Obj-C. The object syntax using brackets instead of dots is apparently uncomprehendable to your average programmer.

      Or rather, the 10 minutes it takes to get used to the syntax is too grand to the lazy programmer.

    2. Re:Strange by DLWormwood · · Score: 4, Interesting
      The object syntax using brackets instead of dots is apparently uncomprehendable to your average programmer.

      I don't know... C++ has some strange syntax and greater-than/less-than usage, especially when you get to using templates.

      Obj-C didn't take off because NeXT didn't take off. The only reason Obj-C is still being talked about is that Apple inherited it for the once and future Mac OS.

      --
      Those who complain about affect & effect on /. should be disemvoweled
    3. Re:Strange by jcr · · Score: 4, Interesting

      I'd chalk that up to history. C++ was promulgated by Bell Labs, and you could get it for free from FSF.

      Objective-C was offered by a tiny software company called StepStone, and for the first couple of years, you had to either buy a NeXT computer for about five grand, or pay StepStone something like $500 for it.

      -jcr

      --
      The only title of honor that a tyrant can grant is "Enemy of the State."
    4. Re:Strange by rixstep · · Score: 2, Interesting

      Thank you, jcr. It was Brad Cox who owned StepStone and who invented Objective-C, and didn't he patent the language?

      A lot of other companies didn't use it, what I understand, because they couldn't access it.

      What a shame...

  3. Re:Why? by JoshWurzel · · Score: 5, Insightful

    Would it not be better to teach the students HOW to program well

    There is. It's called the rest of the CS program at the school. They teach OOP-concepts, algorithms, etc.

    This class is more specific. And optional. No one is forced to take it. And Cocoa isn't a language, its a set of API's. It just happens to use Objective-C. With macs being such a minority in schools, I don't see why its a problem to have an optional (probably student-run) class to each people how to develop for the mac.

  4. Re:Why? by GlassHeart · · Score: 4, Funny
    Would it not be better to teach the students HOW to program well, and let them implement the concepts in the language of their choice?

    You are right, but have you tried putting that on a resume?

    Languages: None, but I program well and can implement the concepts in a language of my choice
    That's the unfortunate fact of life graduates will have to cope with, so every school must cater to the Real World as well, to some degree.
  5. Re:Why? by phch · · Score: 5, Informative

    This class is in the Stanford CS193 series, which consists of lighter workload classes often taken by students outside the CS department, and geared for specific technologies. I don't believe CS majors get much credit for taking these classes. The core CS classes at Stanford are much less focused on details of specific languages (although Java is featured in the main intro OOP class; I guess you have to pick something).

    Stanford has offered classes in .NET, Microsoft MFC, and Java, so a class in Cocoa is not too surprising.

  6. Berkeley teaches Cocoa courses by JoshWurzel · · Score: 5, Informative

    UC Berkeley has already had a handful of Cocoa and mac development courses, most taught by my roommate. These courses, though student run, earned real CS credits and had labs, projects, etc. He just graduated, so someone else will have to take up the torch. And it won't be me.

    Personally, I think its a great idea. Many, many students get out of CS schools with vague notions of how to write a compiler in LISP, or what the best way to implement XYZ (without understanding why it SHOULD be implemented). As if anyone cares. Macs may be a small market, but a Cocoa class is teaching a useful, marketable skill that can be directly applied to real-world application development.

  7. Original headline by transient · · Score: 4, Funny
    Headline should've been:
    [[Stanford alloc] init]
    ;-)
    --

    irb(main):001:0>
    1. Re:Original headline by clarkcox3 · · Score: 3, Funny

      You should probably put something like that in a factory method:

      +(id)stanford
      {
      return [[[self alloc] init] autorelease];
      }

      Then you can just call:

      [Stanford stanford]

      --
      There are no tiger attacks in my area and it's all because this rock I'm holding keeps the tigers away.
    2. Re:Original headline by transient · · Score: 2, Funny

      Yeah but this thread doesn't have an autorelease pool.

      --

      irb(main):001:0>
  8. The markes selects AGAINST elegance by alispguru · · Score: 2, Interesting

    It's called worse is better. Read it and weep.

    --

    To a Lisp hacker, XML is S-expressions in drag.
  9. This course is going to be online. by Anonymous Coward · · Score: 2, Interesting

    The link to scpd.stanford.edu means that the course will be available both online and on tv to all Stanford students and companies that pay for Stanford courses.

    I wonder if my expired stanford.edu account will let me in to view the courses?

  10. Re:Why? Don't Know by WasterDave · · Score: 2, Informative

    Wouldn't it be better to focus (as an elective course) on cross-platform development like Java, which can run on Mac?

    No, because Java on a Mac runs slowly like you wouldn't believe. Objective-C is faster and, honestly, is no harder than Java.

    Apart from the memory management.

    Dave

    --
    I write a blog now, you should be afraid.
  11. University of Yo Yo Dyne by Anonymous Coward · · Score: 2, Funny

    in Grovers Mill N.J. is offering courses in reality distortion fields, does that count?

  12. As a Stanford CS graduate... by John+Harrison · · Score: 4, Informative
    I can tell you that 193 courses are optional and do not count towards your degree. They are offered to give students practical exposure to real world concepts and languages that they otherwise would not get. They are often taken by majors in other engineering departments, so that they can get the programming skills they need for their own projects.

    The Stanford CS courses required for graduation are much more theory based than the 193 series. Even without the 193 series (which many students completely ignore), Stanford CS majors learn to program well. The 106 series is considered a model of how to teach students to program. Business Week even did a large article on it a few years ago. Oh, and we get an algorithms course or two as well.

  13. you want 193J by John+Harrison · · Score: 2, Informative

    I know they offer a similar course in Java because I took it. It just isn't offered for winter quarter. It was a good course, especially considering how new Java was.

  14. Re:what's the difference from C++ by MouseR · · Score: 4, Informative

    One of the coolest features of Objective-C, also available in Java (though I'm no expert on Java), is introspection.

    Through introspection, an object, or a class object (loosely, that's a static class instance for static methods of your class), can interrogate themselves for variable names and types as well as the functions they support.

    Only with object introspection can you send message (aka, method calls) to objects who may or may not understand (aka, implement), said message.

    With this, i've created a really nifty (and open source) SQLite-based object persistence library called Objective-SQL.

    Basically, you just derive a class from my Objective-SQL classes and they can automatically instantiate themselves from SQL table rows through various Find* methods I've implemented in there. Simply change data member values and call [myObject commit] and voila.

    Also, there is relational capabilities given a Category to the system NSString class that allows you to turn an object into a string reference, and this string reference back into an object automatically fetched from the SQL database.

    One could derive the SQLTransport and redirect actual storage and retrieval to other SQL solutions, like PostGre, MySQL, oracle etc.

  15. course website by patrickoehlinger · · Score: 5, Informative

    Following the schema of all Stanford CS courses, it will soon be at: /class/cs193e/
    Since it already has a "Under construction...", the professor's assistant is probably already busy preparing the page.

    --
    >> Had I been going to bed earlier every night? Have I been sleeping later? Has Tyler been in charge longer and l
  16. Re:what's the difference from C++ by awhite · · Score: 5, Informative

    IANAOCP (I Am Not An Objective C Programmer), but from my limited experience, Objective-C and C++ went in pretty much completely opposite directions in how they decided to add object-orientation to C.

    In C++, everything is statically typed, and performance is a primary goal. Objective C has more overhead, but is much more dynamic. Some cool Objective-C features (note: in Objective-C parlance, "message passing" is basically method invocation):

    - Very weak typing. If you want to, you can just pass around all your objects as variables of the built-in type "id", and this allows you to send any message to any object without casting, and of course to build container classes that hold any object. If you want some more typing help from the compiler, you can use typed pointer variables to reference objects, in which case it'll warn you about passing messages that the class doesn't implement.

    - Message forwarding. I've always loved this feature in languages that have it. Makes it so easy to create delegating objects -- you can implement a single "catch-all" type method that allows you to forward any unsupported messages someone passes to your object on to another object.

    - Categories/mix-ins. Add functionality to existing classes without having to extend them. The functionality is automatically given to all instances of the class the program creates.

    - Sending messages to nil (null). Rather than throwing an exception when you try to send a message to a nil reference, Objective-C just returns nil back. Sounds weird, but this actually saves a lot of nil checks in practice.

    - Introspection, which others have mentioned. Facilities to figure out what messages an object or type can respond to, to create new instances given the type name, to send messages based on the method name, etc.

    - Methods as first-class objects. You can elegantly pass around method pointers, and the Cocoa frameworks take advantage of this for GUI callbacks and such. If you're familiar with C# and Java, Objective-C is similar to to C# in this respect, and I much prefer these sorts of method callbacks to Java's system of creating (usually anonymous) listener classes.

    There are a lot of other advanced late-binding things you can do in Objective C too. I have some complains with the language (it's a little too verbose for my tastes, for one), but overall it seems like a great language for building dynamic systems and GUIs.

  17. Re:what's the difference from C++ by bay43270 · · Score: 3, Informative

    Introspection isn't possible without late binding, but not all languages with late binding have introspection. In Java (and other languages) introspection is called Reflection. It simply allows the attributes of an object to be queried. I don't program in C++, but from my understanding, it doesn't have this feature.

  18. Teach general principles instead by ViolentGreen · · Score: 2, Insightful

    Schools should focus on the principles of functional and object oriented languages instead of teaching specific languages.

    If you are solid in the principles of programming, the choice of language shouldn't matter. They will never be able to teach you every language out there. I think it would be much better to have an intro to different languages instead. Perhaps they do; don't really know. I don't think that this is a wasted course or anything. Any additional experience is great. Is this meant as a introduction to GUIs? If that is the case, I'm all for it. Otherwise, I think there would be more benefitial courses in the long run.

    --
    Not everything is analogous to cars. Car analogies rarely work.
  19. ABOUT GODDAMN TIME by tyrione · · Score: 2, Insightful

    The only way I could practically learn Objective-C back in the mid-90s was to work @ NeXT, which I eventually did.

    But how the hell it took this long to get it introduced into any University Curriculum is what truly has been pathetic.

    If you can't introduce this technology to the future developers how do you expect to sell it, beyond the "ease of use" paradigm?

    Hopefully Berkley will be next followed by the University of Washington until the entire Pac-10 offers classes.

  20. Theory Vs. Practice by FugiMax · · Score: 4, Insightful

    I'm of the opinion that language-specific classes are great to have at a college level. Not only can a student get a wide sampling of different languages, but I think it can also teach a lot in terms of language theory. (Common threads in languages, differences in languages, etc.) Also, these classes are almost ALWAYS electives. A CS major not wanting to touch a language-specific class doesn't have to -- it's there as a choice.

    I think a diverse choice of classes using different languages and actually going in-depth into a language itself can be helpful. I mean, there are a lot of optimizations in languages, C for example, that are done by taking advantage of the structure of the language itself -- which one can only discover after diving headfirst into a language. I wish someone would have pointed certain things out to me about C or Java that aren't immediately apparent.

    Bottomline, we're not all out to get PhD's and become evolutionary CS people. Some people just want to learn a language or two, get really good at it, and get a job. Not everyone wants to write a thesis on Compiler Optimizations. :)

  21. Re:what's the difference from C++ by MouseR · · Score: 2, Informative

    I'm a Cocoa developer. I know about EOF, but it's been both canned by Apple, and I am gearing some of my work towards a partial replacement to EOF (at least for my very own needs).

    Objective-SQL also contains a SQLWebForm class whose purpose it to show SQL object data into template pages to yield final html pages.

  22. Very Encouraging by rixstep · · Score: 2, Insightful

    This is very encouraging. What is needed is support from educational institutions like this. Objective-C can cure the IT world of its C++ woes.

  23. I'm glad you asked.. by jcr · · Score: 4, Informative

    why would a C++ programmer want to program in objective C or vica versa?

    This is one of the best descriptions of the difference between C++ and Obj-C, and the benefits of dynamic binding, that I've ever happened across.

    -jcr

    --
    The only title of honor that a tyrant can grant is "Enemy of the State."
    1. Re:I'm glad you asked.. by jcr · · Score: 2, Informative

      Whatever happened to kdyke?

      He's at Apple, in the Graphics & Imaging department.

      If you attended Apple's developer conferences, he usually presents topics related to OpenGL.

      He's got a web site at www.nsobject.com. Some cool stuff there, but it hasn't been updated in quite a while..

      -jcr

      --
      The only title of honor that a tyrant can grant is "Enemy of the State."
  24. Yeah, by ernstp · · Score: 2, Informative

    my school does.
    The cource is called Human-Computer Interaction and it's on the CS Department at Lund University (Sweden).

    http://www2.cs.lth.se/dat006/index.html

    I plan on taking it sometime soon, if they don't cancel the whole cource.

    I've seen them using Interface Builder on their labs and such. Unfortunately we only have 14 Macs, so the excercises may get a little crowded..

  25. Re:Slow Java by oscarmv · · Score: 2, Interesting

    It's actually only the GUI that's quite slow (and it has improved lately since 1.4.1 got released for the mac and all that). Blame that on Aqua if you wish ;o)

    IIRC, pure number crunching Java benchmarks actually give good results (considering the hardware) compared to other platforms.

  26. Cocoa as a good tool for CS learning by oscarmv · · Score: 4, Interesting

    I think no one has pointed this out, but IMHO Cocoa is a great environment (if not outright the best) to learn Object Oriented GUI programming. It tends not only to do things How They Should Be Done, but also gently enforce good practices.

    It's not like people doing CS courses don't use a number of tools they'll never use again after they get their degree (LISP compilers anyone? PROLOG? Obscure emulated environments? Did all those and more... learnt Cocoa in my free time, BTW).

    But in the interest of teaching good programming instead of "what's popular out there now" I'd rather have those coming behind me learning something like Cocoa and then adapting to Java or whatever (whose designed BTW is in many parts based on NextStep) than becoming klutzes with whatever has the greatest demand for code monkeys today.

    Just my .2

  27. Re:Why? Don't Know by McAddress · · Score: 3, Funny

    IANATE (I am not a troll either). I wrote a java implementation of the file browser (Finder), and I am trying to use it to copy a 17.6MB files from my desktop to my home folder, and I have been sitting here for 20 minutes and its nowhere near complete. I could do the same thing on my 533 MHz Celeron in under a minute.

  28. Great! But what about Newtonscript? by csoto · · Score: 2, Interesting

    That's probably one of the best OOP environments yet developed. It would be a great intro to OOP. Too bad there's no real live platform on which to experiment.

    Talk of Newtonscript makes me think of soup, and now I'm hungry...

    --
    There exists no way of exchanging information without making judgments. --Bene Gesserit Axiom