PDA

View Full Version : My first programming language, which one?




Osirius
Dec 22, 2004, 01:09 PM
recommend me a language



Peyote
Dec 22, 2004, 01:17 PM
COBOL

:D


I'm not programmer by any means, but I think Java would be a good place to start. Very similar to Actionscripting in Flash as well.


Once you have Java totally down, ColdFusion is good to know for developing.

Osirius
Dec 22, 2004, 01:33 PM
wait that didn't make any sense

jalagl
Dec 22, 2004, 02:36 PM
I would suggest Java. You can use OSX's dev tools, which came bundled with the OS, and you can find a lot of tutorials online.

i would also suggest C, but it tends to get a bit complex as a first language.

GeeYouEye
Dec 23, 2004, 01:41 AM
For Mac programming, C, followed by Objective-C. Java if you really want cross-platform stuff. C++ is okay too if you don't get too deep into it or you don't want to do much Mac programming off the command line since you pick up several habits which need to be unlearned for Objective-C.

Osirius
Dec 23, 2004, 02:56 AM
okay, i think i will go for java, thanks for the help guys

SkAlex
Dec 23, 2004, 03:44 AM
I just completed my first programming course at NYU and it was in JAVA. I really enjoyed it and found it was a great introduction. The course stressed that a large reason they start with JAVA is its cross-platform use.

blaster_boy
Dec 23, 2004, 04:29 AM
If all you want to do is bang out scripts, or start with that, why not try python. It's used by quite a lot of people, but it is not a compiled language (it pre-compiles itself, but not fully).

http://www.python.org for more info and tutorials :)

Easy to get started, and you can then dig in deeper and deeper. It's very methodical and has a very good feel to it - It's also already pre-installed on the mac, and is cross-platform.

Check http://osx.fresmeat.net for python editors and packages, there are quite a few of them around that work on mac.

jamdr
Dec 23, 2004, 05:48 AM
Java is the best choice for a beginning programming language for a lot reasons that I'm not going to elaborate on right now. It's also a great language for a lot of other things, but for beginners it's really the only option. There is a reason almost all introductory cs courses are taught in Java nowadays.

Java and OS X is a mixed bag. On the plus side, Apple seems committed to Java because it comes preinstalled on every computer. However, historically Java releases on OS X lag behind Windows releases by years. And since Java 5 (the largest upgrade to the Java language since its first release) is going to go final soon, some recent Java software may not run on OS X. Personally, I think Java 5 is an abomination and completely ruins the language in some respects. But the truth is that if Sun releases a new version of Java, OS X needs to support it to keep up with Windows.

There is also the issue of performance. Java is a very fast language when it is run on Windows. The key word there is Windows. Java performance on OS X is less than exciting and Apple seems perfectly content with lagging behind Windows in yet another way. Now, I don't mean to give you the impression that Java is slow on OS X--it is plenty fast for most applications. But if you are creating huge, complex Swing GUIs or graphical games, you will see what I mean. And this is why Mac users generally have some aversion to Java, while Windows users have no such bias. Anyway, enough ranting. Now go learn Java.

Lyle
Dec 23, 2004, 08:41 AM
If all you want to do is bang out scripts, or start with that, why not try python. It's used by quite a lot of people, but it is not a compiled language (it pre-compiles itself, but not fully).I'll second this, and throw in a recommendation for Ruby (http://www.ruby-lang.org) as well. Ruby also comes preinstalled on Mac OS X, and like Python, there are slightly fewer barriers to getting started as opposed to a compiled programming language like Java.

This is not a slam against Java, by the way; it's the language I use primarily at work. It's definitely a programming language that any professional software developer should be familiar with; I'm just not sure I'd recommend it as a first programming language for anyone.

caveman_uk
Dec 23, 2004, 09:24 AM
First programming language - well mine was Sinclair Basic but I'd recommend a language that doesn't teach you bad habits. OOP is all the rage now so I guess Java is a good suggestion. For portability you can't beat C but it's hardly a beginners language. :rolleyes:

atif.muhammad
Dec 25, 2004, 11:21 AM
First programming language - well mine was Sinclair Basic but I'd recommend a language that doesn't teach you bad habits. OOP is all the rage now so I guess Java is a good suggestion. For portability you can't beat C but it's hardly a beginners language. :rolleyes:

yup i totally agree.
i tried to learn C, C++ and JAVA when i was 12 yrs old. i understood C until the bit where it got to arrays.
i've never ever understood C++ and JAVA particularly because of OOP. the books always introduced me to new concepts called inheritance or something like that. i was only 12 and didnt understand a ***** about it. but reading through this thread has reignited my desire to learn Java now that im 16 yrs old and hopefully, i'll understand it better now. cheers people

mms
Dec 28, 2004, 11:25 AM
Sure you can go learn C++ or Java but another good place to start is perl or PHP. Plenty of fun and not so hard to learn. Granted, you won't be writing full-fledged apps with them, but scripting is a good introduction to computers.

Simon Liquid
Dec 28, 2004, 11:54 AM
.

Are you suggesting that you tried to learn Brainf*ck? That's not a good first language at all, in fact I wouldn't suggest that you use it ever.

Mechcozmo
Dec 28, 2004, 12:52 PM
AppleScript
:D

Damn easy, works on any Mac... what else do you want? Oh yeah try this stuff out: tutorials are built in... ultra easy syntax... :D

HiRez
Dec 28, 2004, 01:37 PM
I agree that Java is probably the best one to learn with.

1) You can do everything with a text editor (BBEdit is great for coding) and command-line tool from the Terminal. Later you can move to an IDE like XCode or NetBeans of course, but I think it's good to start with the very basics.

2) It's object-oriented and cleaner and safer than C++. There are no pointers that you can use for pointer math, which is a powerful feature in other languages but also a cause of many many bugs.

3) It has automatic garbage-collection of references when they're done being used (although honestly this can be a point of confusion later on when you use a language that requires more manual memory management).

4) It's cross-platform for just about any OS out there.

5) The most important argument for learning programming in Java is that the amount of offline and online resources you can get is staggering. There are literally hundreds and hundreds of Java books out there, and many online tutorials and Web/Usenet forums for asking for help with specific things. If you get stuck on something, someone will have an answer for you, usually within minutes or hours.

ChrisBrightwell
Dec 28, 2004, 01:58 PM
I would suggest Java. [...]
Ditto that. Java is good for a first language because you spend all your time in the JVM. It protects you from a lot of system-crashing mistakes (like calling an operation on a null pointer) and allows you to become a pretty good programmer since you spend more time focusing on logic rather than error trapping.

Once you get comfortable with Java, though, I'd strongly recommend C and/or C++.

therevolution
Dec 28, 2004, 03:07 PM
Python and Java are both good choices. Python might be a little more forgiving as a first language. Java/Swing is great for getting some exposure to GUI programming.

Of possible interest to you is ESR's take on the subject (http://www.catb.org/~esr/faqs/hacker-howto.html#skills1). Link goes to relevant section, but I think the whole document is a good read.

zimv20
Dec 28, 2004, 05:02 PM
Java [...] for beginners it's really the only option.
wow. i started off w/ BASIC and Fortran, and i turned out okay.

now i'm going to ask the question which should have been asked in post #2. Osirius -- what are you hoping to accomplish through programming?

northen
Jan 8, 2005, 04:06 PM
The language of choice would clearly be ANSI C :)

Very clean and logical syntax, no unwanted abstraction, very well-supported and well-defined :)

And let us just make a few hello-world examples, just to see what you're going to fight with :)

Java
public class HelloWorld {
public static void main() {
System.out.writeln("Hello World");
}
}

C
#include <stdio.h>
int main() {
printf("Hello World\n");
return 0;
}

C++
#include <iostream>
using namespace std;
int main() {
cout << "Hello World" << endl;
return 0;
}

Cocoa/Objective-C
#import <Foundation/Foundation.h>
int main() {
NSLog(@"Hello World\n");
return 0;
}

Python
print "Hello World\n"


Now, these examples aren't much good in reality, but they show off what the language is.

Even though C has some pitfalls in term of memory usage, they aren't that bad, and if you get -the- C book, by Brian Kernighan and Dennis Ritchie (the latter being the original designer of C), called `the C Programming Language` you will learn a lot in a very short time :) Besides, with the knowledge of C, you can quickly move on to Objective-C, Java and C++. Because of my C knowledge, I know those languages pretty well too. But I still prefer C for a lot of things, because of its speed, elegance and simplicity :)

Simon Liquid
Jan 8, 2005, 05:22 PM
Brainf•ck

++++++++[>+++++++++<-]>.<++++[>+++++++<-]>+.<+
+[>+++<-]>+..+++.++++[>++++++++<-]>.<+++++[>++++++++
++<-]>+++++.<<.+++.------.<+++[>---<-]>+.

TrumanApple
Jan 8, 2005, 05:31 PM
i had my intro to programming taught in Ada95 and i learned alot from it... it is very strongly typed so you develop great habits in thinking about data types and explicit type conversions... ada also forces you to keep very good track of actual and formal parameters...

Basicly for real world usage... ada is not really used anymore (cept DOD stuff, real time devices)... but its a great language to learn. Its much more important to learn how to program than it is to learn a language... a good programmer can learn a new language without a problem, so its more important to learn the basics of programming than it is to learn the syntax of a specific language...


but then again im a soph in college and i have only had 1 CS class so far (CS major), so maybe listen to more experienced programmers...

jsw
Jan 8, 2005, 05:33 PM
Java is the best choice for a beginning programming language for a lot reasons that I'm not going to elaborate on right now. It's also a great language for a lot of other things, but for beginners it's really the only option. There is a reason almost all introductory cs courses are taught in Java nowadays.

Java and OS X is a mixed bag. On the plus side, Apple seems committed to Java because it comes preinstalled on every computer. However, historically Java releases on OS X lag behind Windows releases by years. And since Java 5 (the largest upgrade to the Java language since its first release) is going to go final soon, some recent Java software may not run on OS X. Personally, I think Java 5 is an abomination and completely ruins the language in some respects. But the truth is that if Sun releases a new version of Java, OS X needs to support it to keep up with Windows.

There is also the issue of performance. Java is a very fast language when it is run on Windows. The key word there is Windows. Java performance on OS X is less than exciting and Apple seems perfectly content with lagging behind Windows in yet another way. Now, I don't mean to give you the impression that Java is slow on OS X--it is plenty fast for most applications. But if you are creating huge, complex Swing GUIs or graphical games, you will see what I mean. And this is why Mac users generally have some aversion to Java, while Windows users have no such bias. Anyway, enough ranting. Now go learn Java.

I agree - Java is great. Many reasons have been given, and I agree with them all. To me, the single nicest part is the fact that Java GUI coding is both powerful and portable, a big plus compared to any other language. As far as non-GUI programming is concerned, I like a lot of languages (Java, C++, Objective-C, python, etc.) - but, for a beginner, Swing (Java's GUI stuff, essentially) is, I think, a big plus.

As far as OS X support: Tiger has Java 5 built in. That's a relatively minor lag, as it's barely been released on Solaris/Windows and certainly isn't the basis of any major apps yet. So, by late spring, say, OS X will be using Java 5.

Also, as a plus, OS X makes it very easy to use Java as part of an app based on Objective-C, so you can use Java when it's advantageous, then switch to Objective-C when it better suits your purposes.

However, regardless of language, the most important thing to learn while learning programming is how to approach the problem, something you'll work on regardless of language. A good programmer is a good programmer regardless of the language being used simply because that programmer uses good algorithms.

Edit: - just like TrumanApple wrote as I was replying.

But Java is pretty forgiving while being quite powerful, and it's got a stunningly good library of classes that will run on pretty much any platform you choose, automatically.

northen
Jan 9, 2005, 04:16 AM
Brainf•ck

++++++++[>+++++++++<-]>.<++++[>+++++++<-]>+.<+
+[>+++<-]>+..+++.++++[>++++++++<-]>.<+++++[>++++++++
++<-]>+++++.<<.+++.------.<+++[>---<-]>+.

A very obfuscated language. I once coded an interpreter and compiler for a Brainf*ck-like language, which I called SIGI (Sigmund Freud's pet name :P, because it could make you insane :P)

aHpaepalppaopa pawpaoparpalpadpn0 :D

...or my new language, Psilo ;)

main, begin
var,message,string
assign,message,@"Hello World\n"
emits,message
exit,0

...or the C89/POSIX hello world

#include <stdio.h>
#include <unistd.h>

void print( void * str );

main() {
pthread_t hello, world;
char * strhello = "Hello ";
char * strworld = "World";

pthread_create(&hello, pthread_attr_default, (void*)&print, (void*)strhello);
pthread_create(&world, pthread_attr_default, (void*)&print, (void*)strworld);

exit(0);
}

void print( void * str ) {
printf("%s", (char*)str);
}

:p

Of course, if you wanted to print it out in the correct order, you would need a mutex or spinlock of some sort :cool:

northen
Jan 9, 2005, 04:22 AM
I agree - Java is great. Many reasons have been given, and I agree with them all. To me, the single nicest part is the fact that Java GUI coding is both powerful and portable, a big plus compared to any other language. As far as non-GUI programming is concerned, I like a lot of languages (Java, C++, Objective-C, python, etc.) - but, for a beginner, Swing (Java's GUI stuff, essentially) is, I think, a big plus.

As far as OS X support: Tiger has Java 5 built in. That's a relatively minor lag, as it's barely been released on Solaris/Windows and certainly isn't the basis of any major apps yet. So, by late spring, say, OS X will be using Java 5.

Also, as a plus, OS X makes it very easy to use Java as part of an app based on Objective-C, so you can use Java when it's advantageous, then switch to Objective-C when it better suits your purposes.

However, regardless of language, the most important thing to learn while learning programming is how to approach the problem, something you'll work on regardless of language. A good programmer is a good programmer regardless of the language being used simply because that programmer uses good algorithms.

Edit: - just like TrumanApple wrote as I was replying.

But Java is pretty forgiving while being quite powerful, and it's got a stunningly good library of classes that will run on pretty much any platform you choose, automatically.

The main problems with Java (at least how I see it) are:

- Lack of fast, low-level file handling.
- The JVM uses a lot of memory and doesn't start instantaneously; I wrote a simple HTTP server in Java and in C, and tested it on a standard 100 mbit/s network. The Java one delivered about 1 MB/sec and used 20 megabytes of memory. The C delivered 9 MB/sec and used 500 kilobytes.
- It enforces everything upon an Object-oriented programming paradigm, but still includes non-OOP basic types, which is very ambiguous to new users.
- Too much class supplanting. The StringTokenizer class has been supplanted at least 2 times, which is very confusing, because the language often changes too drastically at each major increment
- While usage of the language is free, the built-in classes are incompatible with the GPL, meaning you cannot link non-Java GPL'ed code modules to your Java program (which may still be licensed under the GPL)
- Is only available on major platforms. Platforms like the *BSD's have very poor Java support.

yamabushi
Jan 9, 2005, 05:13 AM
I think one of the C variants is usually the best place to start. Java is also not bad to start with but most people will find C more useful. Depending on what your goals and intentions are with programming one or the other would be more appropriate.

dubbz
Jan 9, 2005, 06:46 PM
Some have mentioned learning C first, but what if your ultimate goal is to program in Objective-C? Couldn't you just skip the first step and just go straight at learning Objective-C?
Any advantages/disadvantages to this?

Maybe I'm just impatient... ;)

jsw
Jan 9, 2005, 07:05 PM
Some have mentioned learning C first, but what if your ultimate goal is to program in Objective-C? Couldn't you just skip the first step and just go straight at learning Objective-C?
Any advantages/disadvantages to this?

Maybe I'm just impatient... ;)
If you're going for Objective-C, then I agree - go there first and skip C.

HiRez
Jan 9, 2005, 07:11 PM
Even though C has some pitfalls in term of memory usage, they aren't that bad, and if you get -the- C book, by Brian Kernighan and Dennis Ritchie (the latter being the original designer of C), called `the C Programming Language` you will learn a lot in a very short time :)Eh...you also might throw up your hands and give up programming in a very short time. The K&R book is a great one, probably the best for ANSI C, but I'd say it is not a good book to introduce someone to programming with. It's very dense and there's little hand-holding. I'd recommend K&R for someone who already knows some programming and wants to learn everything about C.

jsw
Jan 9, 2005, 07:14 PM
The main problems with Java (at least how I see it) are:

I don't disagree that Java has weaknesses; I simply think it's a superior beginner's language because I think it promotes good object-oriented programming technique more than the other popular languages and because it has a GUI. Just my opinion. I used to be a huge C++ fan, never thought I'd like Java. I switched over, and to me it felt like the switch from Windows to OS X.

- Lack of fast, low-level file handling.
Granted, but improving. Java 1.4/5 showed many improvements.
- The JVM uses a lot of memory and doesn't start instantaneously; I wrote a simple HTTP server in Java and in C, and tested it on a standard 100 mbit/s network. The Java one delivered about 1 MB/sec and used 20 megabytes of memory. The C delivered 9 MB/sec and used 500 kilobytes.
Startup footprint is configurable, although I agree never will be as fast as a C app. Not important for a beginning coder, though.
- It enforces everything upon an Object-oriented programming paradigm, but still includes non-OOP basic types, which is very ambiguous to new users.
Yeah, but the non-OOP types are even more transparent in Java 5, and I've never seen them as confusing the programming paradigm.
- Too much class supplanting. The StringTokenizer class has been supplanted at least 2 times, which is very confusing, because the language often changes too drastically at each major increment
(1) The old classes stay around for a very long time, meaning that the old code still works. (2) This is an argument against the class library, and I'd argue that Java has a much better, more intuitive class library than C++ regardless of improvements. (3) This has nothing to do with the language itself.
- While usage of the language is free, the built-in classes are incompatible with the GPL, meaning you cannot link non-Java GPL'ed code modules to your Java program (which may still be licensed under the GPL)OK. Not a fan of GPL, so this has never been an issue for me. I see the point, though.
- Is only available on major platforms. Platforms like the *BSD's have very poor Java support.Again, never been an issue for me, but I see the point. I've run Java apps on Windows, Solaris, Linux, OS X - with no problems. Again, without a GUI, C might be as portable (but requires a recompile). No language has better cross-platform GUI support than Java, and GUI support is, IMHO, important.

Still, these are just opinions. Any language is just a tool. Enjoy any of them!

northen
Jan 10, 2005, 02:40 AM
I don't disagree that Java has weaknesses; I simply think it's a superior beginner's language because I think it promotes good object-oriented programming technique more than the other popular languages and because it has a GUI. Just my opinion. I used to be a huge C++ fan, never thought I'd like Java. I switched over, and to me it felt like the switch from Windows to OS X.

I would, then again argue, that object-oriented programming is one of the most hyped and eventually useless. If you know the types at compile-time, why encapsulate them in an object? I have coded in C++ and Objective-C (two languages with VERY different ways of handlin OOP) - and Java, of course, and it OOP has always struck me with its huge, blown-up way of coding... I can't see it's needed unless you are doing HUGE programming projects. Which is why, I eventually made the switch to C, which (still) is the systems coding language of choice. Also for beginners. Contrary to what most people think, it is actually way more simple and elegant once you really get at it. I would know, I've never had a teacher teach me programming - I had to teach everything to myself with books, and at age 15 I have a programming job for a laptiming company, programming their microcontrollers. :)


OK. Not a fan of GPL, so this has never been an issue for me. I see the point, though.

Neither am I. I find it way too restricted and `socialist` for my purposes (which is why I use the 3-clause BSD license)

jamdr
Jan 10, 2005, 05:30 AM
As far as OS X support: Tiger has Java 5 built in.
Holy crap, I didn't know that. That's...just amazing.

- Lack of fast, low-level file handling.
Used to be quite true, but I find the java.nio package in 1.4 to solve this problem quite well.

It enforces everything upon an Object-oriented programming paradigm, but still includes non-OOP basic types, which is very ambiguous to new users.
If Java didn't have primitives, it would be unbelievably slow. I'm not going to respond to your other arguments because I didn't really understand them. Were you trying to imply that Java is a bad language for network programming because it is too slow? This doesn't make sense to me because usually HTTP servers are going to be limited by bandwidth before they are by processing speed. For this reason, web servers are generally thought to be one thing that the Java language is best suited for, even more so than C because it's much easier to write and maintain. This is why Java is being used more and more in this area.

northen
Jan 10, 2005, 06:03 AM
If Java didn't have primitives, it would be unbelievably slow. I'm not going to respond to your other arguments because I didn't really understand them. Were you trying to imply that Java is a bad language for network programming because it is too slow? This doesn't make sense to me because usually HTTP servers are going to be limited by bandwidth before they are by processing speed. For this reason, web servers are generally thought to be one thing that the Java language is best suited for, even more so than C because it's much easier to write and maintain. This is why Java is being used more and more in this area.

Java's primitives are nice and very useful for programmers, who know, what they are doing. I think the same problem applies to C++'s std.string, std.vector classes, by the way, so don't count me in as one of those ranters that are upset about Java.

I just don't see it as the ideal language, because it has a lot of features, that are confusing to the new programmer. Including OOP vs. procedural.

Which is why, I would prefer the recommendation of C :)

Les Kern
Jan 10, 2005, 06:21 AM
recommend me a language

How about English?
:)
Okay, fun over.

Beginner? Try RealBasic
C? Obj-C?
There's not enough info. What do you want to DO with this language?

ollie
Feb 2, 2005, 05:52 AM
Java is the best choice for a beginning programming language for a lot reasons that I'm not............ersion to Java, while Windows users have no such bias. Anyway, enough ranting. Now go learn Java.

anything java-gui'ed on any of my windows boxes SUCK. slow as peice of crap. im sure java is rant-tastic, cross platform wise. but its slow everywhere...except for my slackware install... (my fastest pc is a 2.8ghz p4 512ddr gf4,slackware pc is 1ghzceleron512sdgf2mx) so yeah. i am biased against java and so are many of my friends. this is using suns VM.

tutubibi
Feb 11, 2005, 01:40 PM
Java is today's COBOL: oververbose, overhyped.

I guess it's OK to learn programming but if you want to write programs fast, Python is way to go.

C/C++ is my still my favourite but Python is amazing language to get stuff done fast. I still miss days of Pascal, Modula-2 and 6502 assembler :( .

jim5
Jan 31, 2008, 01:24 AM
Nearly three years after the last posting, is there anything new to say about any of the languages that were discussed? I am newly interested in the subject. My goal is developing Mac applications.

gnasher729
Jan 31, 2008, 03:45 AM
recommend me a language

English? Knowing English well is good, whatever programming language you want to learn. As a practice run, before you try to learn any programming, try to explain to us why you want to learn to program and what your goals are, in such a way that we can make a recommendation that isn't based on guesswork.

That is one thing that will hit you when you start programming: You have to express your thoughts very, very clearly. Nobody will help you understanding what you mean. A computer does exactly what you tell it to do. It doesn't even try to figure out what you actually want.

So here is the proper answer to your request "recommend me a language":

1. Syntax error. Do you mean "Recommend a programming language to me" or do you mean "Recommend me to a programming language"?

2. After guessing what you meant: "Hi, Suaheli. May I recommend Osiris to you? "

Java is today's COBOL: oververbose, overhyped.

I think you haven't seen COBOL. Maybe three years ago I bought a book about COBOL (it was very cheap, and I was curious), and when I read it, I thought it was just absolutely ****ing unbelievable. From today's point of view, it is just unimaginable how anyone could have come up with a language like that. With Java, you may disagree with some things, you may prefer something else, but the whole thing makes sense. COBOL doesn't. XBase (the dBase programming language) makes sense, and it is ten times more powerful than COBOL at all the things that COBOL is good for.

iSee
Jan 31, 2008, 01:01 PM
Nearly three years after the last posting, is there anything new to say about any of the languages that were discussed? I am newly interested in the subject. My goal is developing Mac applications.

Given your goal, I don't think there is any doubt that you should start with Objective-C and Cocoa (the Obj-C API for Mac OS X developement).

This thread debates Java, but if you narrow the discussion to "Mac applications," Java isn't that interesting.

Also, there are some really good resources for getting started with Objective-C and Cocoa.

Unfortunately, these books are pre-Leopard, and Apple introduced a bunch of new stuff. The books are still quite useful, but there are a few issues:

1. They won't cover "Objective-C 2.0" features like garbage collection and properties. This won't hold you back, but its worth keeping in mind.

2. The biggest problem with these books is that under Leopard, Interface Builder (one of the development tools used in creating Cocoa-based apps) has changed quite a bit. So, you won't be able to directly follow the tutorials that cover it. For that reason, I'd start with Apple's on-line Cocoa tutorial first, which does cover IB 3.0. Then, when you get to an IB thing in the other books, you can substitute what you learned from the Apple tutorial.


First, if you don't know C/C++, I'd start with this book: Programming in Objective-C by Stephen Kochan http://www.amazon.com/Programming-Objective-C-Developers-Library-Stephen/dp/0672325861/ref=pd_bbs_sr_1?ie=UTF8&s=books&qid=1201804866&sr=8-1
It has a very good, step-by-step intro to Objective-C programming that doesn't assume any prior knowledge.

Apple Tutorial: http://developer.apple.com/documentation/Cocoa/Conceptual/ObjCTutorial/01Introduction/chapter_1_section_1.html#//apple_ref/doc/uid/TP40000863-CH13-DontLinkElementID_3

This book is a good book for Objective-C/Cocoa, but does pretty much assume you already know C or another similar language: Cocoa(R) Programming for Mac(R) OS X (2nd Edition) by Aaron Hillegass. link: http://www.amazon.com/Cocoa-Programming-Mac-OS-2nd/dp/0321213149/ref=sr_1_1?ie=UTF8&s=books&qid=1201805099&sr=1-1
I see on Amazon that the 3rd edition of this book is due out in June. Presumably, it will cover Objective-C 2.0 and the Leopard development tools.

MyMacWentBad
Feb 1, 2008, 07:57 PM
C++!!!!!
It is the all in one starter!
If you want to make an operating system (which is unlikly) try PC-DOS!
(Ya, I know, I dragged PC-DOS out of the cobwebs but it's FREE!!!)

skinnybeans
Feb 3, 2008, 05:54 PM
I'd still say java is a good place to start. The way I see it it provides a good foundation for branching out from and learning more specialised languages.

You will learn all the basic stuff that applies to any language (types, control flow) as well as object oriented design and a syntax that is similar to c++ and c#. Also how garbage collection works (relevant now to objective c and c#).

Then if you decide to move to C++ you will need to learn about memory management and pointers, but the syntax will be familiar.

Moving to objective c will be a bit more of a jump as it is syntactically quite different but now that it includes garbage collection, managing objects will be similar to java. (I'm assuming they work in a similar fashion, I haven't investigated the objective c garbage collection).

Also there are a lot of books around about general programming concepts such as design patterns that are written in C++ or Java. It would be quite beneficial to understand at least the basic syntax of these languages so you can get good value from these kinds of books.

Anyway, that's my take on it :)

ArchiMark
Feb 3, 2008, 09:58 PM
How about English?
:)
Okay, fun over.

Beginner? Try RealBasic
C? Obj-C?
There's not enough info. What do you want to DO with this language?

What about REALBasic or Revolution????

Anyone here use either one?

Thanks,

Mark

kainjow
Feb 4, 2008, 12:06 PM
What about REALBasic or Revolution????

I don't think anyone wants to shell out $300 to learn a programming language when everything else is free :rolleyes:. And if you do I feel sorry for you.

I'd say learn C. Learning C is challenging, but simple. Pointer arithmetic is a good thing to understand. OOP concepts can be confusing for a beginner programmer, that's why I don't think Java should be first. If you're learning Obj-C first without knowing C, at some point you will have to go back and learn some C concepts (Cocoa uses several C concepts). Everything after C is cake IMO.

John.B
Feb 4, 2008, 04:28 PM
What is it that you hope to accomplish? Are you learning a programming language just to learn it or are you hoping to develop a particular application? Will this be self-learning or will you be taking a class? What platform are you developing for (OS X vs. Windows vs. ???). Do you want to eventually do this for a living?

I'll assume based on the forum here that you want to write programs on a Mac and for the Mac. If you want to automate tasks or whip up a little application I would start with AppleScript (http://en.wikipedia.org/wiki/AppleScript). (Yes, AppleScript (http://www.apple.com/applescript/).) High level enough to be understandable, practical enough to be useful for every day tasks on your computer, really a good way to get your feet wet. It comes with your Mac. :)

If you are looking for something more formal, a class or a friend who programs will help immensely. There are online tutorials for all kinds of programming languages, but there tend to be tough topics to grasp at first and someone who can look and see what is wrong (not fix it necessarily, just tell you where a mistake is) can be the difference between getting started and quitting in frustration and confusion. If you have a friend who knows C or if you have access to a Java class, that may be the most important consideration. Don't underestimate this.

As to which language beyond AppleScript... Objective-C is really only for OS X on the Mac these days, but likewise, most new Mac development is written in Objective-C and one of the Mac programming frameworks like Cocoa. If you are only interested in Macs then start with Objective-C (it comes with your Mac :)). If not, I'd look at C or a "baby" C++ class or maybe Java (C++ minus minus, C++ with the dangerous -- and powerful -- features taken away). Lots of Windows programming used to be done in VB, but now its mostly done around the .Net ("dot net") framework either in VB.Net, ASP.Net or C#.Net. Either way, once you learn procedural programming and get used to working with objects it'll be easier to move to other languages.

The last thing I'd say is that a programmer/developer spends a lot of time at work not coding but deciphering requirements, designing solutions, working with project plans, debugging things that ought to work but don't, writing documentation and filling out status reports. I can't tell you how many people I've known over the years who were good programmers but just couldn't take working on a development team. Just be aware that there is a lot more to most programmer jobs than writing new code. :)

ArchiMark
Feb 4, 2008, 04:32 PM
I don't think anyone wants to shell out $300 to learn a programming language when everything else is free :rolleyes:. And if you do I feel sorry for you.

kainjow, first of all, please get your facts correct....

REALBasic Personal is $100 and Runtime Revolution Media is $49....both quite a bit lower than the $300 that you plucked out of the air.... :rolleyes:

I'd say learn C. Learning C is challenging, but simple. Pointer arithmetic is a good thing to understand. OOP concepts can be confusing for a beginner programmer, that's why I don't think Java should be first. If you're learning Obj-C first without knowing C, at some point you will have to go back and learn some C concepts (Cocoa uses several C concepts). Everything after C is cake IMO.

My question about RB or RRM was whether or not as a 'hobbyist coder' it might make sense to get one of these as opposed to what seems like a longer learning curve to learn C or some other language.

IF, and I emphasize the word IF, RB or RRM or something else would be easier for a code noob to learn, then MAYBE it MIGHT be worth it for someone like me to spend a few $$'s on it....

Would appreciate any other thoughts on this....

Thanks,

Mark

Fearless Leader
Feb 4, 2008, 04:43 PM
My random(2) cents.

I learned c++ first, then php, then obj-c.

My comments to that is don't do it that way. the c++ to obj-c/cocoa well... will make your head turn a couple of times backwards.

The php I found helpful as its quite human readable and teaches you programming basics, but you can get a lot sloppier with the syntax and could will cause you to have many problems going to more strict syntaxs.

I also write papers and other documents in straight up html code... so I'm a bit wierd.

for cocoa/obj-c I like Aaron Hillgass's book "Cocoa programming for Mac OS X" the third edition is coming out in the spring but the second edition is nice if you don't have leopard. (still nice if you do you'll just have to figure more out with xcode)

kainjow
Feb 4, 2008, 05:59 PM
kainjow, first of all, please get your facts correct....

REALBasic Personal is $100 and Runtime Revolution Media is $49....both quite a bit lower than the $300 that you plucked out of the air.... :rolleyes:

The professional edition (required for cross platform compiling) is $500 so actually $300 is the average price :)

My question about RB or RRM was whether or not as a 'hobbyist coder' it might make sense to get one of these as opposed to what seems like a longer learning curve to learn C or some other language.

IF, and I emphasize the word IF, RB or RRM or something else would be easier for a code noob to learn, then MAYBE it MIGHT be worth it for someone like me to spend a few $$'s on it....

If someone was interested in software development as only a hobby, I would suggest to them to use the Python or Ruby Cocoa bindings. Those languages are easy, quick to learn, less confusing syntax, no messing with pointers, completely free and open source, and since they are bound to Cocoa you get all (well most) of the Cocoa goodness.

lazydog
Feb 4, 2008, 06:00 PM


My question about RB or RRM was whether or not as a 'hobbyist coder' it might make sense to get one of these as opposed to what seems like a longer learning curve to learn C or some other language.


IF, and I emphasize the word IF, RB or RRM or something else would be easier for a code noob to learn, then MAYBE it MIGHT be worth it for someone like me to spend a few $$'s on it....

Would appreciate any other thoughts on this....

Thanks,

Mark

I use RealBasic for some jobs. It's fun to use and very quick to produce results with. It makes building cross platform apps with user interfaces very easy, in fact too easy at times. But I wouldn't want to use it for everything I do. Some things are better done in Java or Objective-C/C++. I think that's the key really - learn more than one language and use what's best for the job.

There's a saying that goes something like this, 'If all you have is a hammer then pretty soon everything begins to look like a nail'. I think that applies to computer languages too.

So my advice to somebody starting off is this: whatever language you learn first… don't stick with it…*branch out. Each language is strong in some areas and weak in others. Finding out these strengths and weaknesses will make you a better programmer.

b e n

ArchiMark
Feb 4, 2008, 06:33 PM
The professional edition (required for cross platform compiling) is $500 so actually $300 is the average price :)

OK, I get it... ;)


If someone was interested in software development as only a hobby, I would suggest to them to use the Python or Ruby Cocoa bindings. Those languages are easy, quick to learn, less confusing syntax, no messing with pointers, completely free and open source, and since they are bound to Cocoa you get all (well most) of the Cocoa goodness.

Thanks for your input, kainjow!

:)

ArchiMark
Feb 4, 2008, 06:35 PM
I use RealBasic for some jobs. It's fun to use and very quick to produce results with. It makes building cross platform apps with user interfaces very easy, in fact too easy at times. But I wouldn't want to use it for everything I do. Some things are better done in Java or Objective-C/C++. I think that's the key really - learn more than one language and use what's best for the job.

There's a saying that goes something like this, 'If all you have is a hammer then pretty soon everything begins to look like a nail'. I think that applies to computer languages too.

So my advice to somebody starting off is this: whatever language you learn first… don't stick with it…*branch out. Each language is strong in some areas and weak in others. Finding out these strengths and weaknesses will make you a better programmer.

b e n

Good to hear about RB and your perspective, Ben....

So, do you think that this would be a good place to start for a 'hobbyist coder' or ???

As to your advice, "don't stick with it…*branch out" do you mean to suggest doing that after you've got a really good handle on the language you learn first or ?

Thanks,

Mark

lazydog
Feb 5, 2008, 09:02 AM
Good to hear about RB and your perspective, Ben....

So, do you think that this would be a good place to start for a 'hobbyist coder' or ???

As to your advice, "don't stick with it…*branch out" do you mean to suggest doing that after you've got a really good handle on the language you learn first or ?

Thanks,

Mark

I'd say give it a go. I think there is a demo version on the RealBasic site. You could go through the tutorial in a few hours.

RealBasic is a complete system and you could probably code most things with it. Yet it's simple enough that you can learn the language and 'libraries' completely in a short period of time. That to me makes it a good candidate for the 'hobbyist coder'. If you end up really liking it, then there is no reason why you can't carry on using it to produce professional quality programs.

However, imho, the speed and simplicity of RealBasic comes at a price: it lacks the depth and refinements other languages/frameworks offer. For example if you want to do 3D then C/C++ and OpenGL are a must.

By 'branch out' I mean don't be tempted to stick with the first thing you pick up. Whatever language you start off with, when you feel comfortable, try a few tutorials of other languages out. Many of the main languages share a lot of constructs so it won't be difficult. You might actually enjoy one languag e more than the other… and then you can become an expert in it!

b e n

SMM
Feb 5, 2008, 10:05 AM
This topic is discussed constantly and I do not think there is any one correct answer. What works best for one person, may not be the same for another. But, I will throw my 2 cents in.

My first language was 8088 assembler. The purpose for learning it was not to gain proficancy, but to learn how computers work (formal class). I then learned COBOL, Basic and Pascal. After that it was C and VB. Now I am converting VB programs to RB. I build business applications, and that allows me to program in 4GLs.

Starting out, I think a good strategy is to first take a class in a low-level language. The idea is to first learn how computers think and work. Then, regardless of where you settle in, you will always have that knowledge (and feel) of what is happening "below the surface".

ArchiMark
Feb 5, 2008, 11:14 AM
I'd say give it a go. I think there is a demo version on the RealBasic site. You could go through the tutorial in a few hours.

RealBasic is a complete system and you could probably code most things with it. Yet it's simple enough that you can learn the language and 'libraries' completely in a short period of time. That to me makes it a good candidate for the 'hobbyist coder'. If you end up really liking it, then there is no reason why you can't carry on using it to produce professional quality programs.

However, imho, the speed and simplicity of RealBasic comes at a price: it lacks the depth and refinements other languages/frameworks offer. For example if you want to do 3D then C/C++ and OpenGL are a must.

Great points, Ben....

By 'branch out' I mean don't be tempted to stick with the first thing you pick up. Whatever language you start off with, when you feel comfortable, try a few tutorials of other languages out. Many of the main languages share a lot of constructs so it won't be difficult. You might actually enjoy one languag e more than the other… and then you can become an expert in it!

b e n

I get it now... Thanks!

:)

ArchiMark
Feb 5, 2008, 11:19 AM
This topic is discussed constantly and I do not think there is any one correct answer. What works best for one person, may not be the same for another. But, I will throw my 2 cents in.

My first language was 8088 assembler. The purpose for learning it was not to gain proficancy, but to learn how computers work (formal class). I then learned COBOL, Basic and Pascal. After that it was C and VB. Now I am converting VB programs to RB. I build business applications, and that allows me to program in 4GLs.

Starting out, I think a good strategy is to first take a class in a low-level language. The idea is to first learn how computers think and work. Then, regardless of where you settle in, you will always have that knowledge (and feel) of what is happening "below the surface".

Excellent points, SMM....while I'd love to take a programming class, unfortunately, my schedule doesn't allow for it....so, whatever I do needs to be something that I can 'self-learn' bumping along on my own with occasional pleas for advice on forums such as this one...

;)

SMM
Feb 5, 2008, 10:13 PM
Excellent points, SMM....while I'd love to take a programming class, unfortunately, my schedule doesn't allow for it....so, whatever I do needs to be something that I can 'self-learn' bumping along on my own with occasional pleas for advice on forums such as this one...

;)

If you cannot take a formal structured class, then the next question which comes to mind is, how good are you of staying on task? Some people take to programming quickly and can learn on their own. But, that can require more time and effort. It is very easy to loose interest, especially if too much time elapses between each focused effort. One way to help counter this is to begin with a high-level language, where you get results and gratification much faster. There is one danger to self-learning; the screwdriver trap.

If a person learns one tool, a screwdriver only, he will feel good building things by turning those screws. However, sometimes he has to use a nail. So, he pounds the nail in with the screwdriver handle and eventually gets the job done. He has completed his task, but he thinks, "that is a lot harder than it had to be. Why doesn't everyone use screws?". Then one day, someone shows him a hammer.

You can give 100 programmers the same functional specifications and virtually everyone will solve it differently. The bigger your 'tool box' becomes, the better work you will accomplish. I think this is one of the major benefits of a structured learning environment.

ArchiMark
Feb 5, 2008, 10:33 PM
If you cannot take a formal structured class, then the next question which comes to mind is, how good are you of staying on task? Some people take to programming quickly and can learn on their own. But, that can require more time and effort. It is very easy to loose interest, especially if too much time elapses between each focused effort. One way to help counter this is to begin with a high-level language, where you get results and gratification much faster. There is one danger to self-learning; the screwdriver trap.

If a person learns one tool, a screwdriver only, he will feel good building things by turning those screws. However, sometimes he has to use a nail. So, he pounds the nail in with the screwdriver handle and eventually gets the job done. He has completed his task, but he thinks, "that is a lot harder than it had to be. Why doesn't everyone use screws?". Then one day, someone shows him a hammer.

You can give 100 programmers the same functional specifications and virtually everyone will solve it differently. The bigger your 'tool box' becomes, the better work you will accomplish. I think this is one of the major benefits of a structured learning environment.

THANKS again, SMM, you really hit the nail on the head!!
Sorry, couldn't resist.... ;)

But your points and analogies are right on target...I can especially relate to your analogy coming from the architecture/construction world.... :)

If you can't get the nail in, just get a bigger hammer!!!
Sorry....

Seriously, I do understand your points and given my age and background/experiences, I've found that I'm extremely disciplined when I put my mind to it and with the right tools and some assistance think I can chip away at it....

Thanks,

Mark

John.B
Feb 6, 2008, 12:20 AM
....while I'd love to take a programming class, unfortunately, my schedule doesn't allow for it....
Just be aware that learning to program is a time intensive pursuit. Your schedule may not allow for sitting in class two nights a week (or whatever) but to be successful you will need to budget time to design, code, and debug your programs. It's really the only way to learn and understand it.

HTH

ArchiMark
Feb 6, 2008, 08:43 AM
Just be aware that learning to program is a time intensive pursuit. Your schedule may not allow for sitting in class two nights a week (or whatever) but to be successful you will need to budget time to design, code, and debug your programs. It's really the only way to learn and understand it.

HTH

Yes, I can definitely understand that, John. Thanks for your input!

Mark

nateDEEZY
Feb 7, 2008, 04:31 PM
If you cannot take a formal structured class, then the next question which comes to mind is, how good are you of staying on task? Some people take to programming quickly and can learn on their own. But, that can require more time and effort. It is very easy to loose interest, especially if too much time elapses between each focused effort. One way to help counter this is to begin with a high-level language, where you get results and gratification much faster. There is one danger to self-learning; the screwdriver trap.

If a person learns one tool, a screwdriver only, he will feel good building things by turning those screws. However, sometimes he has to use a nail. So, he pounds the nail in with the screwdriver handle and eventually gets the job done. He has completed his task, but he thinks, "that is a lot harder than it had to be. Why doesn't everyone use screws?". Then one day, someone shows him a hammer.

You can give 100 programmers the same functional specifications and virtually everyone will solve it differently. The bigger your 'tool box' becomes, the better work you will accomplish. I think this is one of the major benefits of a structured learning environment.

Great advice and analogies! Perhaps I will sign up for night classes to learn C++ after all.

swearbymac07
Feb 8, 2008, 11:40 PM
Applescript is an English Like Language for Programming your Macintosh. Great for Beginners.

e.g:

tell application "iTunes"
previous track
end tell

or

tell application "System Events"
if exists disk "Macintosh HD" then
tell application "Space Checker"
activate
end tell
end if


Hope this helps you.

Cheers