DEV Community

Discussion on: Studying a programming language: tips from a former language teacher

Collapse
 
ronnewcomb profile image
Ron Newcomb

"The best way to improve ones coding skills is to read other people's code,"

Is this actually true? I learned from reading a manual on BASIC and just trying stuff out. I kinda 'felt' my way around how stuff worked. I still believe the best way to learn is to "play" with it, hands-on.

Collapse
 
marydee2001 profile image
Mary Dee

But you have to familiarise yourself with the language first before you can starting playing with it!

I'm a language teacher and I usually suggest my students listen to the target language as much as possible to become familiar with the rhythm and stress, as well as vocab. Obviously you can't listen to code so, per Madeline's post, the next best thing is to read it. :)

Collapse
 
ronnewcomb profile image
Ron Newcomb

Yeah but programming languages aren't actual languages. They're just pseudo mathematical notation. I can't imagine learning integrals by studying someone's derivation of L'Hopital's rule.

Thread Thread
 
marydee2001 profile image
Mary Dee

Why not? No one is saying that learning programming and learning French are identical, but there are similar principles which can be applied.

In English, the spelling of 'night' and the pronunciation difference between 'contract' and 'contracted' makes no obvious sense*. You just have to learn them. Same with spelling: 'i before e except after c', 'q must always follow u' etc. The point is that you look for rules and learn how they're applied and you start to see patterns in how a language works.

I don't think it's a coincidence that A LOT of my higher level students are programmers, and since I began learning tech many of the people I have spoken with online have a background in languages and linguistics.

*The reasons are historic rather than linguistic.

Collapse
 
madeline_pc profile image
Madeline

It's absolutely true that playing around with code yourself is essential to learning how to code. Obviously you are not going to become a great programmer if you only read other people's code but don't write any yourself.

My little quotation is an example of some advice that I've often heard around the internet, and I think that it is good advice. It helps to fill a gap that beginners face after they learn the basics and aren't sure what to try next. I think that both methods are useful. You need to learn by example and try out your own ideas. And of course, find what works best for you, because everyone's learning strategies will be different.