views:

290

answers:

13

This question is for experiences programmers. Do you have a set process that you follow when approaching a new language that you want to learn? Do you prefer learning alone or with a buddy? How do you begin? Do you have a favorite series of books? And is there any place where you can easily get the grammars for the new languages? Do you make a specific sort of cheat sheet where you quickly write down the control structures, and important keywords?

What sort of libraries do you make sure to learn? How do you know that you've learned something and at what point do you feel as if you KNOW a language?

Are there any specific things that you memorize?

When ever I pick up a new language, I mostly waste time fumbling through books which are half for beginners and never for experienced developers. I wish I had an efficient method or a to-do list that I could follow to make the learning process more streamlined.

Thanks

+1  A: 

I read a good manual, and compare it to a language I already know. So i just learn the diff between them.

Stefano Borini
+6  A: 

Personally I find that I need a substantial project to implement in a new interesting language. You can read a book at become familiar with syntax, and be exposed to interesting features, but a nothing gets you thinking in a new language like a project.

Anson MacKeracher
Exactly my approach! Having a purpose and using your final product is essential, because it forces you to go way beyond most books and howtos and therefore this gets you really deep into the product cycle (deployment, refactoring code, versioning, all aspects of IDEs, users). Additionally One final note: Just "reading" stuff often gives the false impression of having understood anything, but often only smattering is the result. Good luck with your next language!
merkuro
I completely agree with this. I often will take a personal project I've been wanting to do and start to implement it in the language I want to learn. It easier for me to learn by working on something "real" instead of looking at an example from a book.
Nick Haddad
Also now that I think of it, it is often also useful to run through a very interactive tutorial. When I was learning Python I read http://www.diveintopython.org/ with a Python interpreter running. I went through the examples and tried my hand at each one.I wouldn't say that I learned Python that way, but it exposed me to some very important concepts early on (plus I got used to the interpreter).
Anson MacKeracher
+1  A: 

a very popular way to learn a new language is to create a simple project for yourself and implement it in your new target language.

akf
+1  A: 

I would create something I've already done before, so I can focus on the language itself, and not the design or the subject of the project.
I would also put some time in searching for (this place is a good starter ;-) and reading a good book about the language.

For the rest it's practice practice practice (like about everything out there isn't it).

fretje
+1  A: 

First step, I write and compile a "hello world" program, usually using copy-pasted source code from somewhere else.

You'd be surprised how often this fails to compile.

MiffTheFox
+3  A: 

I don't set out to merely learn a new language. I find a project that requires (or would be a good fit for) the new language and start coding.

The resources depend on the language, but either an online tutorial or a good "learning the language" book is very helpful. I don't try to memorize anything, just keep the documentation close and search for the solution to each piece of code I need to write. Algorithms don't change much between languages, so most of the time it's just a matter of looking up the syntax for the particular structure I need.

Also, I may never KNOW everything about a language. I just keep consulting the documentation on things that I need and eventually I don't need to look most things up anymore. However, even on the language that I've worked with every day for years, there are still things I have to look up on occasion because I've never used them before.

Dennis Palmer
+1  A: 

reading some online tutorials and most importantly - writing something I need to get done.
The only way to learn a new language is by experiencing it.

shoosh
+1  A: 

I would read some FAQ/book about the big concepts of the langage.

Then i would try to find comparisons between the langages I already know so as to avoid applying in langage X a concept used in langage Y. Each langage as its way to get things done, you shouldn't mix them even if they look similar at first glance.

This would be the first steps.

On a longer basis, I would follow the section dedicated to this langage on a forum or SO. I would read the answers to many threads over the days, so as to grab advanced concepts, tips and most commonly used librairies. This would also helps me to notice when I'm starting to get fluent in the langage : when you start being able to answer to many random questions on a specific langage that means you're getting quite good at it.

Ksempac
+1  A: 

The basics of programming require very few constructs - A good programmer will be able to write great code with only a small fraction of the available language features.

A book is often a good way to learn the basics of a new language and get an overview so you know what areas of that language could help you when you need them later, but then the best approach is to just write programs to do the things you need to do, and learn what you need to know as you go.

The great thing about this is that you know where to look when you want to do something new, and you do things well, but you don't bother to learn loads of junk that you'll never actually use.

Jason Williams
+1  A: 

I usually start off with a few basic programs. Typically samples from the book I'm reading and then modifying them slightly to be more complex and round off the rough edges.

After that, I head over to Project Euler and start rattling off problems. It's a great way to get comfortable with a new language and the basic constructs.

JaredPar
+2  A: 

It's a mad dash.

First I have to make sure I know how to do things the "old" way, meaning the way I'm used to in other languages.

But I don't want to fall into the trap of (for example) writing my Python code as if it were C code, so I read up on all the stuff the new language gives me that more familiar languages don't.

Nosredna
+2  A: 

Here's what I normally do:

  • Read to get familiar with the new language syntax
  • Find an existing open source project I am interested in
  • Port it to the new language
  • Repeat as necessary
Dana Holt
A: 

I usually install the runtime. Then I run some common commands from the command line at the compiler or interpreter. I look online for forums to find out what other think about it. Then I investigate how to work with external parameters such as psvm(String[] args) in java. I guess to sum it up, I am always interested in the languages power on the command line due to my sys admin background in solaris.