Which language would you recommend is the best place to start as a total newbie?

Hello :wave: I started learning to code a while back but found that there was just so much to sift through in terms of picking a clear starting point. The options ranged from focussing on frontend, to getting my AWS Solutions Architect Associate certification.

I’ve now focussed all my attention on learning Go and am really enjoying it but am curious to know if you could start learning from the beginning, where you might start and why?

3 Likes

Hmmm … I started with 8080 assembler, BASIC, dBase II and COBOL.

In our assembler class we acted out how a CPU works, even to the extent of someone being assigned to say, “Tick.”

Despite the so-called dangers of BASIC, it’s still going strong at places like Anywhere Software where products like B4A, B4I and B4J are being used to build software for iOS, Android and desktop devices.

Despite the nay-sayers, COBOL can still provide its practioners with a lucrative career. Hey, we’ve even got a track going for it on Exercism!

dBase II has gone through many changes but is still a strong development tool and is currently represented by X#, xHarbour and Xbase++ (among others).

I get the odd question from folk who ask me what language they should learn. I usually ask them to rephrase the question as what languages they should learn, and then I suggest taking one from each of the major language families, e.g. FORTH, LISP, functional, logic, declarative etc. Each will teach a problem-solving approach and when you’re trying to get a job, having a few skills under your belt is worthwhile.

Think of it this way: if you’re a labourer and you turn up to a building site and say that all you know how to use is a shovel, you probably won’t get a job there. But if you turn up with varying levels of skills in shovel, pick, wheelbarrow, cement mixer, screed, level, hammer, screwdriver, and nailgun then your likelihood of being employed there is considerably higher.

Of course, everyone wants to know what the failure-free entry point into the field is. Short answer: there isn’t one. Language fads come and go, so spread the risk by learning a few.

3 Likes

I’m not sure that Go is the easiest language to start out with. But what is a good language to start with? I think there are lost of aspects to what makes a language good to start with:

  • Amount of syntax: some languages have a lot of syntax, which you need to know and memorize, so usually less syntax is easier
  • High-level/low-level: low-level languages can be quite daunting, as you usually have to do more yourself than in higher-level languages (e.g. memory management)
  • Supported paradigms: for beginners, imperative code is often seems to map fairly well with how they think computers work, whereas a functional approach might be somewhat trickier to start with
  • Documentation: the better a language’s documentation, the more likely you’ll be able to find solutions when you’re stuck
  • Community: how easy is to get help from others?
  • Compiled/interpreted: requiring a compile step can be a barrier towards getting started, as you feel like you can’t even get your code running at first
  • IDE: is there a editors/IDE that supports the language? A good IDE can really help pinpoint bugs, suggest fixes, etc.
  • And there are probably many more…

Taking these criteria into account, my suggestion would probably be Python.

7 Likes

Or FORTH (or one of its dialects, like 8th). FORTHs don’t have a lot of syntax; they can be both high and low-level; they’re imperative; there’s plenty of documentation; there are many communities; most are interpreted but many can be compiled; and there is support in many IDEs. The counter-claims are the Reverse Polish Notation (RPN) syntax and the stack-based calling convention.

1 Like

I think it really depends on what your goals for learning a language are.

  • If you’re primarily looking to make yourself employable or work on a particular project ASAP, the most applicable language for that career/project is probably the best choice – for example, Python/numpy for data science, C# for game design with Unity, Javascript for web design; there’s generally a lot of good applied beginner material aimed at people looking to get into a specific field
  • If you’re interested more in the underlying theory of CS, picking up a language introduced in a book like Structure and Interpretation of Computer Programs (which uses Scheme) or How to Design Programs (Racket) is a good idea; the languages themselves aren’t likely to get you a job anywhere, but they lay the foundations for understanding how programs work and instill good habits for how you approach projects in mainstream languages

Since programming skills are transferrable between languages – every language will have at least something you can learn and apply elsewhere – in the end, the best language to learn is the one that keeps your attention the longest. It took me a lot of false starts with languages like Python and C++ before I found Scheme, which has a paradigm and syntax style I found a lot easier to work with, and with the knowledge I picked up learning it I was able to go back and bolster my skills in the languages I had trouble getting a handle on.

7 Likes

Hey @jimpjorps - thanks for your considered and helpful response, I really appreciate it!

I’ll certainly try take a look at some of those recommendations you’ve made as am intrigued to get a deep understanding. Invariably, I started to look at coding purely as it was a pragmatic and sought after skill, but am realising that underpinning the skill, is so much content and thinking

Ideally, the one that you have the most fun in!

If you’re desperate for a job and have a specific field you can enter, then learning a specific language might make the most sense, but ideally you want a language that you can feel competent and comfortable in as quickly as possible, and where you can just discover the joy or programming.

The language should ideally get out of the way and let you start learning to problem-solve using code, not give you more to learn. It should be as obvious and straightforward and simple as possible, and teach you as little Computer Science as it can get away with. Then as you grow and the fundamentals feel less like a game of Jenga it can introduce other ideas and start to teach you more about how languages can be powerful.[1]

Part of choosing that language is then probably about what feels fun. Want to mess around with real world things like Arduinos or Rasperry Pi’s, then choose something (e.g. Python) that’s great for that. Want to do animations - maybe start with (modern) CSS[2] then move to something more powerful like JavaScript. If you want to make games, then find some basic scripting language like LUA that you can find good tutorials for.

Fundamentally, what’s going to get you to the point of being a programmer isn’t the language itself, its the fact that you can muster enough willpower and self-efficacy to keep going, and the more fun (and less frustration) you’re immediately having, the more likely you’ll achieve that :slightly_smiling_face:


[1] (There’s a small [tiny really - almost not worth talking about], chance that we’re currently writing our own language to achieve this :wink:)
[2] CSS might sound like a terrible choice, but you can use variables and functions in it, so as a way to grasp some fundamentals in a very restricted but immediately useful way, why not?

8 Likes

My first programming language was QuickBASIC 4.5, which I taught myself in the early 90’s from the book that came with the media (Learn BASIC Now, it was called.) After all, BASIC stands for “Beginner’s All-purpose Symbolic Instruction Code”, so it was made for beginners. Visual Basic .Net might be considered the contemporary equivalent, although it is more complex than the earlier BASIC, and is also somewhat of a second-class citizen behind C# for the .Net platform.

Some people might recommend C as a first language so you start with an understanding of how memory is handled. They see the learning process as starting with the low-level details and building up from there. Others might recommend starting with a garbage-collected language as being simpler, and trying manual memory management later. They see the learning process as starting at a higher level and then drilling down into the details.

So, what language you choose might depend on what learning style you prefer.

2 Likes

I think any language can be a good first language, but at the same time, I think in a way, they are all bad. So my advice would be to pick one that sounds fun and can do something you want to do and go from there.

The way I see it, the perfect good first language for learning ideally would:

  • Have a minimal setup and do not depend heavily on external tools for that setup.
  • Get you started quickly. You should be able to create simple programs without knowing too much other than the basics (what is a statement, what is a variable, what is a loop, etc…).
  • Be there for you when you eventually learn more. As you move away from simple programs, learn about new concepts in programming and start building more complex things, this language should have some implementation of these concepts. You shouldn’t have to consider learning a new language to put into practice a particular concept just because your language doesn’t happen to have some form of that concept. You are busy learning your first language, that’s already a tall order. This language shouldn’t implement all the concepts in the universe of course, a set of the most common ones would be enough.
  • Have simple syntax, just so when you look for help or are checking other code in that language, you are not confused by the syntax or the 100 alternative ways there are to do something.

Looking at the languages I know, I feel all of them fail in at least one of these points, which makes it hard to recommend just 1 language. Ideally, if you are starting to learn to program, you would learn more than one language, so that you are exposed and can put into practice more concepts. But that’s not realistic, since learning to program and learning the first language is already overwhelming as it is, the last thing you need at that point is someone telling you “btw, also learn language X”.

With that said, my recommendation for a first language would be Python. Despite not being a perfect first language, why I think Python is probably the best option:

  • Really easy syntax that can get you started quickly. You can just start writing statements in a file without any boilerplate and run those.
  • Huge amount of amazing libraries that you can play with. No matter what you want to do, there’s almost certainly a good Python library that can help you do it.
  • Interpreted language, which makes it really easy to test individual lines of code in the interpreter. You don’t have to compile a whole program or bother to write tests just to test a snippet of code quickly.
  • You can use it to learn concepts of object-oriented programming and even functional programming.
  • It’s fun. My experience is that writing Python is a lot of fun, which is very important too! With a few lines of code, you can achieve a lot. You feel immediately productive.

The shortcomings of Python as a first language:

  • Not statically typed. Types are an important concept in programming, but by default in Python, you don’t need to declare any types. Python does support type annotations now, but they are not common in my experience, and you do need an extra static type checker like mypy to actually check your type annotations, Python will ignore them by default. This makes it so transitioning to a statically typed one will not be as smooth as it could be.
  • Interfaces, as in a type that declares the methods that other classes must implement, is also an important concept in a lot of languages. It’s easy to declare interfaces in most languages, but convoluted in Python.

In the end, no language is a perfect first language, so I’d say to pick something that is fun. Any language one chooses will have shortcomings and hurdles. In my opinion, the success of learning to program and learning a first programming language has more to do with factors like motivation and looking past those hurdles than with the language itself that is chosen.

5 Likes

I would say python, because of its strict syntax and very good error handling. The language syntax is fairly easy to understand and there is a lot of libraries for it so you can do a lot of stuff.

Although if you have experience in html/css you may want to get into javascript/typescript. Since that is more or less a requirement for frontend. Although javascript has some weird syntax which can be hard to understand.

I seccond python :snake:
It’s really easy to learn the syntax, which enables you to learn basic programming concepts which you can later transfer to working in other languages.
It’s particularly nice for a newbie to work with python and django to start building web apps (which then incorporates the javascript, HTML, and CSS)

2 Likes

The question is incorrectly formulated. What do we understand by the term “beginner”? A 5-year-old person or a 50-year-old computer user who wants to learn how to program? The answer will be different and it will be based on a specific person. For a child 5-10 years old, my answer is Scratch, a simple online editor in which you drag blocks and see your program, as well as the result of its work immediately.

For a 15-25 year old student, the answer is “what do you need? what is the name of your course?” and here the choice is huge: Python, JavaScript, C/C#, Ruby, etc., thousands of them. For an elderly person about 50 years old, their parameters are important and Lisp, C/C#, Rust, Haskell and others are quite possible here. So there will be no right answer to this question.

Unexpectedly, the most correct answer to this question is Russian education, the student is offered a choice of 4 languages: 1) Python, 2) C, 3) Pascal, 4) algorithmic language. And this is like a starting point, after which a person can go his own way.

2 Likes

I don’t think Rust belongs to the old people, I am 26 and learning it. It’s highly used in blockchain.

2 Likes

I didn’t mean that Rust would be interesting only to old people. This is a complex language and I would not recommend learning it first. As for the blockchain, my choice is Solidity, it is simple, effective and created specifically for it. If you are 26 age and you are already studying Rust, then I can say: bravo! Good luck and good code!

1 Like

I do not think student age considerations are at all useful, past 12–16 years of age and quite possibly (much?) younger. In my experience, once someone wants to learn a specific programming language, they totally can, regardless of age or language.

It seems to me motivation is so important that it outweights almost all other factors, except insofar as they might reduce motivation.

Also, that Haskell be a ‘complex’ language is an unhelpful myth. I will not debate the issue here (as it is off-topic), except to – relevantly – point out that (relatively) many have learnt it as their first programming language. (One prominent example.) The same probably goes for other ‘complex’ programming languages. Indeed, I reckon the situation is similar to the one with spoken languages: all are roughly equally complex (at the equilibrium balancing compactness and comprehensibility), but the way this complexity is distributed varies from languages to language. (See also: English from the Ukrainian POV, analogous to ‘exotic’ programming languages seen through the eyes of users of ‘normal’ ones.)

1 Like

Thanks, yes Rust is a complex language for beginners and has a longer learning curve, Solidity is good for Ethirum-based blockchains. But, Rust has some unique features like its memory management, optimization, and speed so I chose it as I also have prior experience in Java so it’s not that tough to learn.

I feel I ought to make a case for Clojure but, well I haven’t personally reached a level where I can demonstrably say “It worked for me!”.

But that’s ok, because other people have. In fact it’s the whole premise that Clojurebridge (which follows the railsbridge model) is based upon:

Clojure is a relatively new programming language that values simplicity, expressiveness, and practicality. The simplicity of the language makes it excellent to learn if you are new to programming and a pleasure to use, either way. Its expressiveness and practicality make it a language that gives you a lot of power to turn your ideas into working software.

I can, however, speak to why it happens to click with my brain, and why I’ve continued to stick with it despite its admittedly abysmal job market. Don’t get me wrong - there are actually plenty of Clojure jobs out there… if you’re already a mega-genius with 10+ years of experience. But I don’t make life decisions based on financial incentives because I hate money.

In a word: interactivity.

Jack Rusher recently explained it better than I ever could in his talk
Stop Writing Dead Programs, Strange Loop 2022 (jackrusher.com), but to get a quick taste of what I mean, there’s a demo I made earlier this year for a Clojure TDD library.

It’s interesting to note that Clojure devs aren’t generally very enthusiastic about Test-Driven Development, because we have REPL-Driven Development (a concept which has made its way into F#) which kind of makes that workflow unnecessary, since writing Clojure involves a unique process of arbitrarily evaluating tiny bits of code from within your editor.

This is almost impossible to explain with words, you really have to see it in action. But it’s totally Clojure’s killer feature that makes me feel like I’m coding in the dark when I try to use any other language. Your program is a living thing that you can introspect however you like, which allows you to wrap your head around the code in tiny, digestible pieces instead of having to trace the entire flow of execution in your head.

3 Likes

It depends of course but in general I would recommend Elm.

Some pros are:

  • Small language
  • Consistent, everything is a function and work in the same way.
  • A helpful compiler. Elm has the best and most useful error messages I’ve seen so far. This helps the beginner to help themselves.
  • Optional type annotations, a beginner can start without them and still get help from the compiler. Though the compiler sometimes gives better help when you have annotated your functions.
  • Elm is made for making web applications so you typically start quite early with some visual representation of your program that is highly interactive and the threshold for doing so is low compared to some languages. I think this helps some stay motivated because it’s fun to see things happen. Great for doing small games this way.

Someone mentioned that beginners tend to think more in ways closer to how imperative programs and therefore functional programming languages can be trickier but I’m not entirely sold on that. I don’t have any data to back any statements up but I’ve heard many who has done a lot of math find non-imperative languages such as Elm quite intuitive. I’ve also heard people teaching Elm to both first time coders and experienced coders that in some aspects it’s more difficult to teach the experienced coders (if their experience is mainly from imperative langs) than to the first timer. Maybe there is something to that, maybe not. My first lang at university was a FP-lang, a Lisp, and I think that was a good language to start with. I’m not saying there is a strong advantage of learning FP before imperative but I don’t think it should be discouraged if done right.

Another good beginner language that might already be the first contact for most people is Excel :D

  • You learn some basics about writing functions
  • Your brand new programming skills give you some real value immediately, assuming you have some kind of excel that you use for work or private economy etc.
6 Likes

@jonathanmiddleton it seems you might still remember being a complete beginner. (I have forgotten, surprisingly thoroughly, as have many.) What do you reckon are the most helpful kinds of answers to your kind of question?

1 Like

Firstly, thank you all so much for the in depth responses and considered breakdown of why you’d recommend certain languages.

I’ve really enjoyed reading through all the comments and feel that there has been a really wide range of languages recommended.

On reflecting about @MatthijsBlom question, one of the biggest challenges I faced when starting out on the programming journey was conceptualising how a language practically interfaces with the real world…if that makes sense? The bridge between the theory and the practical implementation always felt quite wide in difficult to bridge.

As such, the responses that I feel I connect well with, are the responses that have connected a real-world application, with the rational for why a specific language makes sense.

Interestingly, I started learning Go because I had a friend who raved about it. In all honesty, many of the reasons he liked it flew right over my head. But as I’ve learnt about what happens on a really low level (e.g. how memory is apportioned and used), it’s allowed the language to be much more understandable.

The reality though, is that learning something new is challenging, but I’m so excited and grateful for the different perspectives shown in this thread and feel that I could make a much better decision about what language I would want to start out with, based on all the comments above.

I’ve realised, that I enjoy a strict compiler though, and that I have many preconceptions that still affect which languages I think I’d enjoy. Definitely the next step is to work through all the languages in this thread using Exercism and then maybe I can give my own piece of advice to another lucky person!

4 Likes