DEV Community

loading...
Cover image for Which programming language should I learn first?

Which programming language should I learn first?

Simon Barker
At CareerSwitchToCoding.com I am on a mission to get every developer get their first job with more than "just make a profile and apply"
Originally published at careerswitchtocoding.com ・1 min read

There are so many programming languages, so many platforms and so many ways to learn. Even knowing how to get started can be stressful.

“What if I choose the wrong language?”

“What if it doesn’t do what I need it to?”

The truth is there is no wrong first language. You will hear strong voices in favour or against every language under the digital sun, most of them will have valid points however, all of them will miss one key thing.

Learning to program is different from learning a programming language.

Programming languages are a tool that enable you to learn how to write code and solve problems. Most languages share similar underlying concepts, so concepts learned with one will apply to most of the others.

You don’t want to hear me waffle on about ideological aspects of programming vs programming languages though, you want an answer!

Learn Javascript first.

It’s the only language that is natively supported in web browsers, it can run on servers, it can run locally on your computer and you can even build mobile applications for iOS and Android with it. At this point, Javascript is the universal language. So, as a starting point, it’s perfect.

Once you have a good understanding of Javascript you can then move on to other languages that are more specific, if you want.

Your first language is not your last language, no language is wrong but Javascript has the broadest application.

Discussion (19)

Collapse
arvindpdmn profile image
Arvind Padmanabhan

JS is a good start. Beginners should also in parallel learn the programming concepts, not just blindly learn language syntax. For example, naming conventions, clean code, OOP, etc. As an example, see devopedia.org/object-oriented-prog...

Collapse
efpage profile image
Eckehard

Yes, but one step after the other. For a small project, bad code may serve well. If you get in trouble with your spaghetti, it´s time to think about concepts.

Collapse
allthecode profile image
Simon Barker Author

Totally, the language is a tool to learn programming 😀

Collapse
efpage profile image
Eckehard

Javascript has made a good progress over the last years, so it is definitively an option. As mentioned is is freely available in each browser. As JS has no strong type checking, errors will only be detected on runtime, so a good debugger is very important. Luckily VScode provides excellent tools for that.

Using OO-concepts is important for advanced programmers, that need to make their code more maintainable. I often enough started a project using simple functions. After some time, groups of functions became visible, that shared the same task. Often this was the point to build functional units, which could be better represented as classes.

A programming paradigm is a support, not a religion. If you learn about OO, maybe some day you will find the concept helpful to make your life easier. If it does not help you, why use it? I always felt that code should grow in a natural way. The more effort you pay to build well designed classes should pay back very soom.

Collapse
allthecode profile image
Simon Barker Author

Before I programmed professionally this is how I coded and it was more fun. Thinking about it this is how i still code on side projects

Collapse
efpage profile image
Eckehard

Ok, maybe it is not that anachistic. But even on a professional project you you will reach a point where the codebase grows too large and you need to rethink the structure of the whole project.

Collapse
oaraujocesar profile image
César O. Araújo

The problem in learning JavaScript first is about the OO paradigm. It's not so common doing things that way in JS but I agree with you that is the most valuable first step. I also would advice to start learning JS + some strongly typed language so that you can take the most of most used things in programming world. I started only with JavaScript but if I knew how I would need to know about things related to OO and stuff, I'd start learning some language related to it from the beginning.

Collapse
allthecode profile image
Simon Barker Author

That's a good idea, perhaps once comfortable with syntax and program flow have a play with TS. I learned C first so had to worry about types but I just don't think that's a good starting point today unlesss you are following along with something like CS50.net (which is still my number one recomendation to people)

Collapse
peerreynders profile image
peerreynders • Edited

Perhaps that is the wrong question to ask:

Quote

It’s mind boggling that your HtDP students are better C++ problem solvers than people who went through the C++ course already.

Quote:

It is not only the violin that shapes the violinist, we are all shaped by the tools we train ourselves to use, and in this respect programming languages have a devious influence: they shape our thinking habits. This circumstance makes the choice of first programming language so important.

Austin, 12 April 2001
Edsger W.Dijkstra
To the Budget Council concerning Haskell

Collapse
allthecode profile image
Simon Barker Author

This is interesting, although people often need quick feedback when learning something new (especially when learning on their own) and trying to run a program and getting immediate feedback will keep them moving forward. Perhaps reading these alongside learning would be a good mix

Collapse
peerreynders profile image
peerreynders • Edited

It's not universally popular with learners given their general impatience to get going and the common assumption that the skill of designing programs can be acquired as a byproduct of learning a programming language.

Obviously this group of educators and researchers believe that starting with a "commercial" language can have downsides for many - and students often only appreciate this after years of practice and learning languages across multiple paradigms (even when moving from imperative to relational).


FYI:

Collapse
ganeshh___ profile image
NGS Harsha

we run into a lot of problems while learning new language, we get stuck or cant find the solution easily so if you are in college, learn the language that is most used by your fellow students, it will be easier to get help

if you are starting on your own, learn the language that has a big community e.g. Python, JavaScript, Java, C++ etc...

if you are looking for a job, learn the language that is popular/offers good salary among the compines in your area

Collapse
allthecode profile image
Simon Barker Author

I think JS is probably the most likely langague to meet that criteria but if you work in an area with lots of iOS agencies then Swift would be a better fit most likely

Collapse
bhargu27 profile image
Bhargav kanodiya

i have learnt c and c++ first but if you will learn c++ or javascript first it will be great start

Collapse
allthecode profile image
Simon Barker Author

My first language was C, nearly 15 years ago!

Collapse
higker profile image
Jarvib Ding

Rust!has a bright future in the next 10 years.👌

Collapse
allthecode profile image
Simon Barker Author

I agree I just don't think it's broad enough right now to be a first language 😀

Collapse
matengodev profile image
Davis O Matengo

Learn Java first.. Everything else will be much easier...

Collapse
efpage profile image
Eckehard

...and the mount everest is the best place to start climbing...