I want to learn programming - which language to start at?

Discussion in 'Mac Apps and Mac App Store' started by cb911, Aug 1, 2004.

  1. cb911 macrumors 601

    cb911

    Joined:
    Mar 12, 2002
    Location:
    BrisVegas, Australia
    #1
    hi,

    i'm thinking of giving programming a shot, i'm just wondering where to start. i should be able to do some sort of programming class at the college i'm at, but i don't have a clue where to start.

    i'm kind of wondering what language should i learn if i want to be able to make apps for UNIX/Windows/Mac? is there one that covers all of those platforms?

    any advice for this programming n00b is much appreciated. :)
     
  2. bousozoku Moderator emeritus

    Joined:
    Jun 25, 2002
    Location:
    Gone but not forgotten.
    #2
    Any more, C is a lowest common denominator for programming across platforms. You could also do C++ but it can be a lot more complicated. Java is also available and is less complicated than C++ but requires a special environment that can be a pain to set up on platforms other than Mac OS X.

    JavaScript is something you might want to try and it's available within the safe environment of a web page. Create some HTML and embed some JavaScript. It's not a full programming language but it's a good, uncomplicated way to start.
     
  3. jefhatfield Retired

    jefhatfield

    Joined:
    Jul 9, 2000
    #3
    at the local jc, where many take programming for the first time (many hs students also take classes at the college), they have it set up this way

    beginning programming...C/C++

    intermediate...advanced C++

    advanced...visual basic and java with a strong recommendation that java comes last since it's much more complicated than visual basic

    ...so what did i do? i started with java...and it was painful ;)
     
  4. BakedBeans macrumors 68040

    BakedBeans

    Joined:
    May 6, 2004
    Location:
    What's Your Favorite Posish
  5. cb911 thread starter macrumors 601

    cb911

    Joined:
    Mar 12, 2002
    Location:
    BrisVegas, Australia
    #5
    no i'm not musically talented. i couldn't find the C sharp key either... :p

    okay, so C or C++. i'll check it out. as long as it's nothing like the 'assembler' language. i've heard some real horror stories of people that program that stuff. :eek: :D

    i was thinking of JavaScript, since that's similar to C. i read that it was similar to C (or C++?) but simpler and not as rich as a language.
     
  6. ddtlm macrumors 65816

    Joined:
    Aug 20, 2001
    #6
    AL-FAMOUS:

    Cause it was made by MS. Does it even run on Macs? Meh, even if it did why would anyone not MS-centric choose it over something like C, Java, Ruby, etc...
     
  7. Nermal Moderator

    Nermal

    Staff Member

    Joined:
    Dec 7, 2002
    Location:
    New Zealand
  8. blaster_boy macrumors 6502

    blaster_boy

    Joined:
    Jan 31, 2004
    Location:
    Belgium
    #8
    If you want to ease in and do some (web or file) scripting, you could go for python ( http://www.python.org ) or perl - works on all platforms (must be installed in windows, but is already installed on mac os x and most linux distros).

    Otherwise, if you want to also do graphical stuff across the mac/linux/win, I've heard good things about RealBasic.

    Myself, I use Python to write a script here and there, as I find I can read and understand what I wrote about 6 months ago (try that with Canything or perl). Plus it's got modules you can load for just about anything you want to do as a system admin (ftp, syslog, whatnot).

    As for C,C++, C# I always found it too much hassle... but YMMV ofcourse.
     
  9. panphage macrumors 6502

    Joined:
    Jul 1, 2003
    #9
    If you want to do Cocoa, Objective-C is the way to go...for a total n00b you might wanna set your original sights a bit lower and try to pick up something like python, which is pretty easy to pick up while still being very, very powerful.

    If you want to do OOP cross-platform, C++ or Java are probably your most common choices. In this case PHP might be an okay start as PHP5 has really cleaned up PHPs OOP. If you're interested in OOP, it's best to start out with a powerful OOP language, no sense learning procedural programming and unlearning it all later. Smalltalk is absurdly object-oriented but I don't know how useful it is (I don't think it's all that common anymore) or whether it's easy to pick up.

    For those looking for the sharp, try holding down your shift key while pressing the "3" key. C# ;)
     
  10. angelneo macrumors 68000

    Joined:
    Jun 13, 2004
    Location:
    afk
    #10
    A quick question. How popular is python and perl for web applications now? What is the frequency when client required their applications to be in python or perl. Do you guys still programmed in perl and python? I'm just curious that's all.
     
  11. broken_keyboard macrumors 65816

    broken_keyboard

    Joined:
    Apr 19, 2004
    Location:
    Secret Moon base
    #11
    I don't recommend C as your starting point. Try Pascal, it doesn't have much commercial application but it will give you a good solid understanding of the basics.
     
  12. blaster_boy macrumors 6502

    blaster_boy

    Joined:
    Jan 31, 2004
    Location:
    Belgium
    #12
    In our company, most intraweb stuff is done in .asp and/or bought content site programs - but Perl is the official script language, and as such in used in quite a few front-end applications, message gateways, etc. (I work in a bank, btw).

    We have one website that was developed externally that works on php.

    Python is very powerfull, is easely readable, but here is not much used. I just get a headache from understanding perl programs, so I bucked the trend and learned Python.

    PHP is also easely learned (my little server in the company runs mainly on php).
     
  13. JFreak macrumors 68040

    JFreak

    Joined:
    Jul 11, 2003
    Location:
    Tampere, Finland
    #13
    i think every universities (of technology) teach programming with C language, and although it has steeper learning curve than some others, once learnt, the C programming skills can easily be translated to other programming languages.

    if you're looking for an easy-to-learn (scripting) language, that would be perl. the syntax is as close to human thinking as it comes, but it is not very powerful language.

    i recommend java only if you already have basic C programming skills. it's a bad language for learning programming basics, really.
     
  14. Nermal Moderator

    Nermal

    Staff Member

    Joined:
    Dec 7, 2002
    Location:
    New Zealand
    #14
    Objective-C isn't THAT hard...

    [myTextField setStringValue:mad:"Hello World"];

    Easy :)
     
  15. cb911 thread starter macrumors 601

    cb911

    Joined:
    Mar 12, 2002
    Location:
    BrisVegas, Australia
    #15
    thanks for all the comments. :)

    i think they teach Delphi (very similar to Pascal?) at my college as the 'beginning' class.

    broken_keyboard, you mention getting a good understanding of the basics? i'm wondering what is there to learn about the basics? things like syntax and how to format the code?

    and say i start on Pascal, that's right down the bottom end of the programming food chain, right? what things can you do with pascal? and if i start off with Pascal, realistically how long before i'm making small apps for OS X/Linux or Win? it's not that i've got some dream to be a developer, i'm just curious. :)
     
  16. bousozoku Moderator emeritus

    Joined:
    Jun 25, 2002
    Location:
    Gone but not forgotten.
    #16
    Delphi uses ObjectPascal, a Borland variant.

    I had learnt Pascal when it was in vogue. It is neither an easy language nor an easy entry into programming because it harbours some very confusing aspects, such as procedures within procedures.

    The good thing about Delphi is that you don't have to do those odd and confusing things to accomplish a lot. As far as I know, it was the second drag-and-drop programming environment for Windows and much more successful than Visual BASIC. Many Visual BASIC applications graduated to Delphi years ago. I found it great for creating visual interfaces quickly that could call substantial and lean processes coded in C++.
     
  17. broken_keyboard macrumors 65816

    broken_keyboard

    Joined:
    Apr 19, 2004
    Location:
    Secret Moon base
    #17
    No, syntax and formatting are largely superficial. I mean things like modularity, flow control, basic data structures. In all these fields, Pascal is very strict and will get you in to good habits. The trouble with languages like C and Perl is that they let you get away will a lot of messy stuff (especially Perl). If you start out with a very strict language, then those good habits will stay with you. Also if you start with a more limited language it forces you to think harder about how to solve problems, then when you eventually get to C and Perl you appreciate their powerful language features more, and have a better understanding of when it's appropriate to use them (and when not).


    It really depends on you. If you really, really in a hurry then I would suggest skip Pascal and go straight to Java. Java is also pretty strict with you about clean code. The trouble is it has automatic memory management which you won't appreciate if you have never had to do it manually. Also it has a powerful standard library, with most everything you could want right there - you could really benefit from implementing some of that stuff yourself. Also lastly it is OO. You would be forced to learn OO at the same time as the basics. If you have written large programs without OO you would more clearly grasp the benefits first hand, instead of it just being some theory written down on paper.
     
  18. scottwat macrumors regular

    Joined:
    Oct 9, 2003
    Location:
    Ohio USA
    #18
    What to learn

    Well I started out on c++ for unix using gcc. The mac really is a great programming platform. With free developer tools and tons of languages ported to it. You have everything from perl to ruby to python and C, C++, java, fortran, you name it, except for the microsoft stuff it's available on the mac. So with all the options you need a good platform to learn. You need to learn about data types, methods or functions depending on what language you use, you also need to learn the syntax of a particular language to get good at it. For the most part data types and methods are similiar in all languages. You also need to look at algorithms, or the way things are done. Also your language choices should reflect your level of patience and your end goal. If you aren't very patient a quick scripting language like python, perl, php is pretty quick to do decent stuff. PHP is a web scripting language so if you leave more to web development you could try it out. If you have some patience then you should try - c/c++ or java.
     
  19. tace macrumors member

    Joined:
    Oct 13, 2003
    Location:
    USA
    #19
    Pascal?

    I agree that starting with Pascal (or Delphi) is somewhat of a wise move as it has been mentioned. It is a strict and a very structured language, so it is a good language to start out on.

    Java is not as difficult as people make it out to be. If you want to built GUI front ends than some of the freely available IDEs do a pretty good job of handholding. C and C++ are obviously decent and very powerful languages. But I do not recommend them to a beginner. There is so much you can do wrong with those languages and you would have no clue why. Java has a much better/modern model in that it is a "safer" language to try things out on.
     
  20. cubist macrumors 68020

    Joined:
    Jul 4, 2002
    Location:
    Muncie, Indiana
    #20
    But there is no Pascal (Delphi) for Mac, is there? MPW, maybe?

    I'd recommend Java, as it's just about as easy, and much more marketable.
     
  21. brap macrumors 68000

    Joined:
    May 10, 2004
    Location:
    Nottingham
    #21
    I'd start with Visual Basic under VPC.

    No, don't laugh. it's the quickest, simplest way of getting the hang of the constructs and principles you need to be able to know as second nature whilst programming. It's also still developed, and the speed tradeoff with C++ is negligible today. Nobody uses Pascal, man. Naturally there is a limit (and a nasty one to get over) to which you can do with such a simplistic language.
    Once you're interested, go straight into Java or C++ on the platform of your choice. You'll love the hands-on control, especially with C++ - my favourite language. It's got it's own little quirks, but the experience you have with VB should get you through in principle, at least. Java is awesome in that the libraries you get with it are hu-uge. You have to do very little to get going in a Java app, but again it has it's own quirks. It's also truly cross platform GUI compatible, something you may find really, really useful.

    Ugh, anyway, I hate computers, just my personal experience. A historian's life is so much more.... outside :D
     
  22. whooleytoo macrumors 603

    whooleytoo

    Joined:
    Aug 2, 2002
    Location:
    Cork, Ireland.
    #22
    Java is (IMO) a very easy to learn development language/environment. It's syntax is very similar to C, so it should be relatively easy to move between the two.

    The one drawback is that if/when you move from Java, you'll have to learn about memory management - since Java handles most of that for you. So, it's a nice shallow learning curve to start with, but it'll get steeper later on.

    Another option is to learn the programming basics and principles in C, then you can move from there to object oriented programming in either Java, C++ or Objective C. Note, C++ and Obj-C are both supersets of C, so still have the syntax and functionality of C (plus a whole lot more).

    Of course, if you're developing for OSX, Obj-C is probably your most forward-looking option. While I personally have my gripes about it (including lack of multiple inheritance and operator overloading), the amount of work you'll be spared by using the Cocoa frameworks is well worth it.
     
  23. cb911 thread starter macrumors 601

    cb911

    Joined:
    Mar 12, 2002
    Location:
    BrisVegas, Australia
    #23
    thanks for all the replies. i think i've learnt more about programming from this thread then i ever knew.

    i'm going to talk to some of the lecturers at my college and see what they recommend, and it also has to fit in with me existing time table. so i'm pretty sure it'll be either JavaScript (or some other web-oriented language) or Delphi. i'm not *really* keen on getting into developing apps and stuff, i just want a taste of programming, for now. so i might try Delphi. :) but i'll see what happens. also, i'll be joining the class 3 weeks into the semester, so that might affect things.
     
  24. scottwat macrumors regular

    Joined:
    Oct 9, 2003
    Location:
    Ohio USA
    #24
    PHP

    I might be wrong but PHP would probably be easier and more functional. I never really cared for javascript.
     
  25. whooleytoo macrumors 603

    whooleytoo

    Joined:
    Aug 2, 2002
    Location:
    Cork, Ireland.
    #25
    That might not be a bad option. Plus, you can move on from there to developing Dashboard gadgets, if you choose to take it a step further.
     

Share This Page