How do you write code? And how do you choose which coding language to learn?
On this page we'll look at some of the different coding languages out there and how you might pick which one to start learning.
Coding languages (aka programming languages) are ways of writing your commands for the computer. These are then 'run', which means they are translated into something the computer can interpret and then the computer tries to do these commands.
There isn't just one coding language because there are so many different things you might need to do with computers and many different kinds of computers. Each coding language has been designed by people, often with particular tasks in mind.
Below are some examples of code that would display Learn to code! on the screen in different coding languages. Above each example is the name of the language, in case you're interested.
Python:
print("Learn to code!")
HTML:
<p>Learn to code!</p>
Ruby:
Puts 'Learn to code!'
JavaScript:
console.log("Learn to code!");
Scratch:
if coding-language == "right" {
learn coding-language
} else {
keep looking for coding-language
}
Sadly, there's no code like that above, which would tell us which one to learn. Instead, you have to make your own decision, based on what you want to do and what might be useful to you. If that sound daunting, we've got some tips on things to consider and some information on the different kinds of coding you might want to do.
When choosing what to learn, it can be useful to know about some of the broad categories of kinds of coding languages there are, and to think about what they might allow you to do. Here are a few different kinds of coding and some languages used for them.
Think about why you're interested in learning coding, using these questions to help:
Now, look through our criteria below and then through the pages on different coding languages to see what matches up with your answers.
When you're new to coding, it can be hard to know what to look for. Using the criteria below to help you evaluate which coding language(s) to learn when looking through our pages or searching online to research different coding languages or ways of coding.
Always remember that it doesn't matter too much which coding language you choose, as all of them will help you learn key concepts and make it easier to learn another one in the future. There are a lot of transferable skills, like the computational thinking we looked at on the Introduction to coding page.
This practical guide has our resources on learning to code generally and materials on learning specific coding languages, but we can't cover everything! So how do you find other material and evaluate what might suit you?
Materials and courses on coding can vary not only in terms of which coding language they teach or what kind of programs you create, but also how they are delivered and how you might interact with them.
MOOCs, or massive open online courses, are a way of taking an online course that has structure and can have exercises or assignments to create. These can take a couple of weeks or many, may have a specific start date or be generally open, and are often designed and run by universities and tech companies. Sites like Futurelearn and edX have a huge range of MOOCs, not just on coding, that you can find and join (be aware that although these are generally free to take part in, you may only be able to access some features if you pay for a premium upgrade).
Books and websites can be designed as a self-paced course, perfect if you don't have a large block of time to devote to learning coding at once and would prefer to set your own schedule.
Most coding languages also have a range of reference sites, which are places that contain lists of the commands and features of that coding language and guidance on how it works. This material can be useful if you already know some basics and want to know more. Often these sites have some introductory materials or exercises too. These are entirely self-directed and don't always have a clear structure to work through.
Face to face or live online courses can be useful if you like structure and time set aside to learn something, but these are less likely to be free. Members of the University can book onto our upcoming training sessions (we often run sessions on coding).
When looking for and evaluating courses and online learning material, you'll need to keep an eye on any prerequisites in terms of prior knowledge and also what device you might need. Some coding courses require a particular operating system (e.g. some courses for creating iOS apps require you to have a Mac computer) or the ability to install certain software.
Also think realistically about what time commitment you can make. If you don't have much time for learning coding, maybe that 12 week course is a bit ambitious to start with. A shorter course or single set of exercises can help you learn some coding and feel like you've achieved something without needing to make a bit commitment.
Just as you might do with other kinds of information, you need to be critical and evaluate the information and online courses you find.
Look at who is providing the course to see if they might have any bias. For example, a course made by a technology company might be focused on using that company's products - which may or may not be what you're looking for!
Also keep an eye out for if the materials or course are free, and if so, if there's any limitations placed on the free version. Lots of free online courses are only free if you 'audit' the course, meaning you can see the materials but not do any assessments or graded exercises. You may also not be able to get a certificate to prove you completed the course.
Use the material on this page to consider which coding language you want to learn, if you don't know already.
Below you'll find links to pages we have on specific coding languages, and help on finding good sources of advice and free materials for other coding languages.
If you're still not sure what to learn, you could try Codecademy's quiz to find your "programming personality" to give some suggestions.
You could also explore our creative coding page for inspiration on what kinds of coding to try.
You might find it useful once you've read the page to look through the pages on specific coding languages to get more of an idea of their features and how you'd go about learning them.
Coding languages we have support pages on:
More pages and resources will be added as this guide grows. Use the 'Feedback' button on the side of this page if you have any suggestions for future content.
You might want to try out something that is less traditionally like coding, but still has elements of coding. For example, spreadsheets' formulae can work like coding (they even have IF functions). Lots of interactive story tools like Twine use coding-like language, and even allow you to incorporate web coding like CSS and JavaScript into your creations.
For more inspiration on "creative" coding and how you might fit coding into your work, see our Digital Creativity Practical Guide.
If you're looking to do data analysis with coding and need some help with what methods you might use, which coding languages to try, or how to get your data into the right format/shape for analysis, see our Analysing Data Skills Guide.