If you’re considering learning how to code, you have probably been wondering what programming language you should start with. And that’s a great question, because choosing your first programming language will definitely have consequences in terms of what kind of projects you are going to be able to build and what companies you might work in one day.

That’s why we chose to make a comparison between JavaScript and Ruby, which are both good languages to start learning how to code. Both have advantages and disadvantages, and it often depends on what your goals are.

Let’s dive in!

Origins

Ruby was invented in 1995 by Yukihiro Matsumoto, who “really wanted a genuine object-oriented with easy-to-use scripting language”.

JavaScript was also invented in 1995, but it was built in 10 days by Brendan Eich and was initially thought to be only used in the browser as a front-end language.

This had a few consequences…

Syntax

Ruby’s syntax is easier than JavaScript’s. It is short, easy to visualize, and often has only one way of achieving a result.

On the other hand, JavaScript has a lot of curly braces and other “weird” punctuation which might seem a bit off-putting for beginners. It also has multiple ways of achieving a result. It’s true it can sometimes be harder when you have a choice in how to achieve something : just like in cooking where it’s easier to follow a rigorous recipe than to actually cook by choosing the ingredients yourself.

Different uses for different people

All in all, you might ask yourself: why should I learn JavaScript over Ruby? Seems like a lot of work for similar results, doesn’t it?

Well, Ruby is indeed an easy first step to learn how to code. But learning how to code is rarely the end-result you are seeking. There’s probably a reason why you want to learn to code, usually building projects, landing a job in tech, or interacting better with developers.

And it turns out that, since its beginnings in 1995, JavaScript has evolved into quite a sophisticated and powerful language.

One of the biggest changes in JavaScript’s evolution is the creation of Node.js which has transformed it into a front-end AND back-end language. That means that you can actually build a full-stack Web application using only ONE language. React (released by Facebook in 2011) is another framework that has made JavaScript more powerful on the front-end side of Web applications.

Turns out React and Node.js are the top 2 “most wanted” technologies by developers according to Stack Overflow’s 2018 survey, meaning these are the frameworks most current developers want to learn. As far as programming languages go, JavaScript is #2 in the “most wanted” list (at 19%), right behind Python (at 25.1%) which we teach in our Data Analytics course, while Ruby sits at the 16th position at 5.7%.

https://insights.stackoverflow.com/survey/2018/

Another huge advantage of JavaScript is its speed. Or rather Ruby is suuuuper slow compared to most programming languages, as you can see in the below table :

https://codeburst.io/javascript-vs-ruby-vs-python-which-is-the-best-language-for-your-startup-e072b14bebc7

Speed is crucial to a programming language because it defines how fast your application will be able to perform tasks. For certain tasks, JavaScript can be up to 20x quicker than Ruby (https://www.educba.com/javascript-vs-ruby/), making it a good choice to reduce your costs as your application scales to millions of users. Indeed, performing the same task with JavaScript requires less computing power than with Ruby, meaning that your server infrastructure needs to be a lot more robust if you are using Ruby and want to have the same output as if you were using JavaScript.

All in all, the fact that JavaScript can be used to build a full-stack application and that it is a lot faster than Ruby has turned it into the more popular language. Uber, Paypal, LinkedIn are some examples of companies who have switched from Ruby to JavaScript in recent years.

A direct consequence is that there are a lot more Web development jobs for JavaScript than there are for Ruby. If you check Indeed.com, you’ll see 8000+ jobs recruiting JavaScript developers in Paris, whereas only 600+ for Ruby.  If your aim is to land a job in tech, there is no question: you should choose JavaScript over Ruby.

If you want to launch a Minimum Viable Product (MVP) for your future billion-dollar startup, then maybe Ruby is the way to go because you’ll spend a less time learning and a more time building. Though you should consider the fact that you will probably have to switch to another language if you are indeed successful!

So why are most bootcamps teaching Ruby?

Most bootcamps are teaching Ruby because most bootcamps were launched in 2012-2013, when Ruby was getting all the hype. Back then, everyone wanted a Ruby developer, and then Node.js and React came along, changing everything. It’s worth mentioning that Ruby can still be a viable option if you are in a “learn fast build fast” mindset (like being able to code a simple website without having to learn too many things).

Here at Ironhack we adapt as quickly as we can to the market requirements, so we have chosen to teach JavaScript and React in our Web Development Bootcamp, for now…

And that’s also why we teach Python in our Data Analytics Bootcamp, as Python is #1 for any data-related jobs.

If you want to learn more about our bootcamps, feel free to check our website!

Want access to our curated Web Development Content Library ?

Want access to our curated Web Development Content Library ?

Leave us your email and we'll send you the link !

You have Successfully Subscribed!