New to programming...

Discussion in 'Mac Programming' started by zosoeffex70, Oct 28, 2005.

  1. macrumors newbie

    Feb 17, 2004
    Durham, NC
    I'm new to programming of any sort and wanted to learn C/C++, Java or Python languages and do it on my Mac, but I'm a little lost as to how to use these languages for programming on the Mac. Where do I find the right, preferable FREE, software to do that?

  2. macrumors 601


    Jan 6, 2004
    Western US
    Install the Xcode developer tools from your Tiger (or Panther) CD/DVD. You might actually be able to do Python without installing the tools (it's a command-line tool), I can't remember if it's installed in the normal version or not. But anyway, Xcode is Apple's free development IDE that can handle most of the things you want. There are other options for Java development as well, such as NetBeans, Elcipse, and others, but you'd have to download and install those yourself. If doing Python development, you will probably want a good text editor with Python syntax highlighting. I recommend the free TextWrangler, which you can find on Best of all is for you to use the SEARCH feature on this forum to find other threads about this, your question has basically been answered many times already. Good luck.
  3. macrumors 6502a


    Jan 8, 2004
    To program C and C++ on the mac you can use apples xcode, its free. You can download it from the Apple Developer Connection.
  4. thread starter macrumors newbie

    Feb 17, 2004
    Durham, NC
    Got it thanks. Will search more and I appreciate you input/help!
  5. thread starter macrumors newbie

    Feb 17, 2004
    Durham, NC
    Excellent, I have it (just recently downloaded it) and wasn't sure of it's potential and with your suggestion I will read the documentation and get started.

    Say, do you know of any good books that would get me started programming in C w/Xcode as a beginner?

    Thanks for you help! -gene
  6. thread starter macrumors newbie

    Feb 17, 2004
    Durham, NC
    Thanks, this is very helpful - I appreciate you time and quick input! -gene
  7. macrumors regular

    May 6, 2003

    C++ Primer Plus by Stephen Prata is a very good book for beginners if you want to learn C++.
  8. thread starter macrumors newbie

    Feb 17, 2004
    Durham, NC
    Thanks - will note that book. Also, I read in Absolute Beginner's Guide to Programming - Greg Perry - Que Publishing that Visual Basic was a great place to start programming and then perhaps C before C++ or Java since the latter (2) were similar to C and that it would be a good foundation. Now I've learned that VB isn't done a Mac and that it's a 'legacy language' that will soon lose support from MS.

    I haven't programmed a lick and just want to figure out the best place to start and do it using my Mac. I guess I need to learn how to use Xcode AND beginning programming - kinda feels like a catch 22.
  9. macrumors member

    Jun 3, 2005
    Xode's native coding language is Objective-C, which is supposed to be an easier to learn and use than any other C dialect. Also, maybe you would like to give Xcode's AppleScript Studio a go before actually going into C.
  10. thread starter macrumors newbie

    Feb 17, 2004
    Durham, NC
    Good deal - thx! I also ran across this info:
    Later, Gene :cool:
  11. Nuc
    macrumors 6502a


    Jan 20, 2003

    If MS drops support for VB what programming language will they have for excel?

    Also could someone point me to a good place on visual basic, I've been trying to do some programming in excel. Trying to link a fortran code w/ excel using VB.

  12. thread starter macrumors newbie

    Feb 17, 2004
    Durham, NC
    Have you stopped by:
    May be a good resource.

  13. macrumors 603


    Oct 16, 2003
    Visual Basic is horrible from a programmers perspective. You'll be better off by starting with a proper language. C++ is most powerful, but it can be complicated. Java is very tidy and strict, easier than C++, but not as powerful. Some like Python, but I don't know too much about it. I think the advantages of Python is that it has some convenient solutions and has a clean and simple syntax.

    If you want to use Xcode, Objective C is the easiest language to use. Xcode and Interface Builder works best with Objective C.
  14. macrumors 603


    Dec 19, 2002
    Ugggghh...Fortran. :eek:

    for the OP: If you really want to use XCode (which is an awesome App) go for Objective C which will integrate well with the interface builder, which is a lifesaver. :)
  15. macrumors 68000


    Jun 6, 2003
    District of Columbia
    Get started in Obj-C. A good book is the Aaron Hillegrass (Hillegass?) book. There are others...did you read the sticky in the developer's forum? Also, go on usenet and look at Lots of helpful people there.
  16. macrumors 6502a

    Stop ...

    and take a couple of minute to think aboute why you want to learn programming?

    Do you have an idea for some great programme you want to write?

    Are you generally interested in computers and want to take that interest one step further?

    Are you tired of manually doing stuff that really should be automated?

    What sort of person are you?

    Do you want quick, instant rewards - do you need to get a task done, quickly, and then move on to the next. Do you have a hundred ideas running about in your head that need to be fleshed out before the next hundred come along and take their place?

    Are you methodical and pedantic? Do you have the time and motivation when yet another, 'one more', tiny, frustrating error crops up. Will you keep pushing on in the face of complexity and frustration? Do you have some grand plan in mind, where every detail matters. Do you insist on perfection and knowing every tiny detail of your projects?

    Choosing a programming language to learn really depends on all these things. Most important is to remember that any language is a tool that you use to implement your ideas and as such you need to choose the right tool for each job, so if you fill in a bit more background it will be much easier to give you some good advice.

    With nothing else to go on, I would suggest that Python is a good language to learn for a beginner. It is very easy to get started with. It has a fantastic amount of depth. It encompasses everything from web programming to 3D graphics. You name it, it is there.
  17. macrumors member

    Oct 23, 2004
    Chapel Hill, NC
    Jsut my $0.02

    At least from the view point of being a n00b in general, and learning java, I found Xcode quite a bit less than intuitive. But your experience maybe different. If you do have trouble with Xcode specifically, you should know that there are other ways to get your feet wet in programming for free. Pretty much every company that makes a program for writing code offers a free version. Personally I'd recommend Eclipse, but that just me.

    Anyway this website might be helpful if you have no other access to programing info:

    Just a word of warning, most of these aren't written with the mac programer in mind, so while the principles of the programming language are the same, the specifics of using Xcode won't be covered. I bought 2 books trying to figure out how to use Xcode, neither of which were as helpful as the Xcode Documentation. You should download the documentation from Apple Developer Connection (you can get an account for free) Once you have the documentation and it is installed, open up "Xcode User Guide" and start reading. It will actually be Xcode 2.1 User Guide, or whatever version of Xcode that you are using.
  18. thread starter macrumors newbie

    Feb 17, 2004
    Durham, NC
    • Automation: YES, YES, & YES!
    • I'm fascinated with computers/apps/internet
    • I could sit in front of my laptop or any computer for hours without interruption and be very happy
    • I'm sure I experience frustration when things done work perfectly, but I lie awake at night searching my mind to figure out solutions - a quiet time for an epiphany or the occasional 'EUREKA!' and experience a great sense of satisfaction once a problem is resolved/understood.
    • Ideas for programs do come to mind; not really a constant flood of ideas - but I think that some of that creative spark will be enhanced once I begin to get my feet wet with coding and see what's really possible
    • My inclinations are towards order, detail, use, function & asthetics

    If I start with Python will C/C++/Java be harder to learn? One author stated that C is a good place to start as it builds a solid foundation to learn other 'C similar' languages. Have you found/seen/heard that employment opportunities for Python programmers are abundant/in demand? I guess I have a dual goal of learning a language that will also facilitate employment.
  19. thread starter macrumors newbie

    Feb 17, 2004
    Durham, NC
  20. thread starter macrumors newbie

    Feb 17, 2004
    Durham, NC
  21. macrumors 6502a

    Harder to learn than if you try to learn programming with no previous experience? I don't think so.

    But learning a low level language will help you more in learning higher level languages than learning a higher level language will help you learn the lower level ones.

    The thing with the lower level languages (C/C++, I would probably address Java as slightly higher level) is that there is much more to write to get simple tasks working. What the lower level languages do offer though, is a good insight into how a machine actually works. It is far from necessary to know this to deliver functional, working programmes. The learning process will be much slower, especially if this is self directed learning, and rewards much more spread out.

    A week into learning any programming from scratch, it is probably a good level of achievement to have a console app (i.e. run through Terminal) that reads input and offers some sort of response (whooop-di-do!). A month in to a higher level language and you will probably, depending on direction, be able to offer useful web scripting functionality or be touching on aspects of GUI design and graphics. With a lower level language, you will probably still be wrestling with concepts like memory management and pointers.

    That is not to say that these languages do not have their place - some of the stuff I am working on at the moment involves billions of calculations and the performance overhead of Python just does not make this a feasible option for running on a regular basis (I still used Python to prototype my algorithm, though). By comparison, I attached some back-end functionality to a website through CGI using Python; I could have used C++, the functionality is still there, but the same task, mostly text / xml processing, would have taken at least twice the time.

    Having come from C / C++ to higher level languages, the word I use is describe it is 'rewarding'. There are some surveys on google (er, somewhere) asking programmers what they think about their languages. Ruby and Python were reliably the ones that people actually enjoyed using. Go figure.

    As for job opportunities? Much harder to say for a specific language (flick through some recruitment websites) but again you will get to a commercial level of quality (god, I hate that phrase, there is some horrendous stuff written to get something through the door and actually doesn't mean very much at all) in a high level language faster than in a language like C. You won't find that many openings if you have less than 2 years experience in C++, again that's "commercial" experience. I have seen people employed with basic / rudimentary PHP skills employed in entry level positions and who have moved up very quickly to interesting and rewarding projects as they have learned skills on the job.

    So, hopefully my previous comment is a little more in context. There is much to be learned from low level languages. Yes, they offer a good foundation to build upon. But, that comes at a price. they can be frustrating with few rewards. Development can be slow and tedious. But if (er, when, naturally) I have that "one great idea" for the archetypal killer app, it is very unlikely that C or C++ is going to be my first port of call. I might come back to it later, but for getting my ideas fleshed out, I need to have skills in a language that allows me express what ever insane, whacked out thought has crossed my mind, not one that requires levels of concentration that would make Uri Geller quake in his boots.

    As for automation bit: well, if you are just doing repetitive tasks, moving files, you could do worse that spend an afternoon playing with and picking up bash scripting. Along with a handful of common command line UNIX programmes, it is an extremely powerful tool. Flick through Part 1 of to get a picture. For more Mac-centric stuff, have a look at Apple script.
  22. thread starter macrumors newbie

    Feb 17, 2004
    Durham, NC
    Thank you for your well-thought out and helpful response. This helps me to see the trade offs between low/high level languages. I may be going to a community college for a (2) yr AS program and I think it is focused on the low-level languages such as C/C++ and the like. (Although, I'd like to get started - got a coupla months before classes start - with a high level language; perhaps REALbasic...)

    Do you mind if I republish your comments on my blog? It could use some substantial input as I find this was.

    Again, thanks for your time and thoughts!

  23. macrumors 6502a

    Go for it. Copy anything you like.

    One analogy that came to me is in the field of image processing. As with all analogies, a pinch of salt is required.

    It is much easier to use something like Photoshop (the high level language) to apply named filters and effects to process your image. Behind the scenes, you have the mathematics of convolution, Fourier transforms, Gaussian distribution etc. etc. that you can learn about and understand (low level programming language).

    Does knowing this detail make you a better graphic designer? Hmmm, I don't know. It can obfuscate the issues, especially early on and the maths is harder for many people to understand than the visual output. Ultimately it probably makes you more capable of building on the work of others, extending the existing tools and which can result in superior work - you are better able to express uniquely and individually your ideas. It gives more insight into the domain.

    It might certainly help learning Photoshop though, e.g. all the little tool parameters have a precise meaning. Change to another app, and they are still there, despite maybe different names. Knowing Photoshop though is not really going to subconsciously turn you into some mathematical genius.

    The cost of course being that you are probably making fewer posters / adverts / layouts. It's just not possible if you have 1000 pages of theoretical mathematics to plough through before you start publishing.

    The best artists, though, will be the ones who can use the appropriate tool at each stage - use stock tools where necessary, but with the knowledge to custom build a suitable plug-in or processing step where needed.
  24. macrumors 603


    Jul 23, 2002
    Fuquay Varina, NC
    I wouldn't consider C/C++ as low level languages, both provide much abstraction as to what is really going on at a hardware (machine code/assembly) level...I guess its all relative, but having exposure to x86 assembler, C and C++ are a godsend.
  25. macrumors 6502a

    Well that's fair enough but the OP was talking about C/C++, Java and Python, an assortment of 3rd generation languages ;)

Share This Page