Computer Languages

Computer Languages

High Level Languages

  • High level languages are more understandable to humans compared to low-level languages. Examples are Python, Java or C#.
  • Less memory efficient compared to low-level languages, but are easier to write, maintain, and debug
  • Supports multi-threading and can be run on any platform with the right interpreter or compiler

Assembly Language

  • Assembly language is a low-level programming language for a computer or other programmable device.
  • Directly corresponds to machine language instructions which are specific to each computer architecture
  • Harder to write and understand, but gives programmer more control over hardware
  • Requires assembler to convert Assembly code to executable machine code

Machine Code

  • Machine code is a computer programming language that is directly understandable by a computer’s CPU.
  • It is written in binary and is very hard for humans to read or write.
  • It is the most fundamental level of programming and provides higher execution speed and more efficient use of memory.

Interpreted Languages

  • An interpreted language is a type of programming language for which implementation executes instructions directly, without previously compiling into machine-language instructions.
  • Execution is slower than compiled languages as each instruction is read, interpreted and executed every time the program runs.
  • Examples include Python, JavaScript and Ruby.

Compiled Languages

  • A compiled language is a programming language whose implementations are typically compilers and not interpreters.
  • Involves converting source code into machine code before execution.
  • Once compiled, execution is faster than interpreted languages.
  • Examples include C, C++ and Swift.

Comparison of Languages

  • Selection of a language for a programming task depends on factors such as the nature of task, expected speed of execution, hardware and software resources available, skill level of programmers available, etc.
  • Understanding pros and cons of different languages helps in making this decision. For instance, for tasks needing direct manipulation of hardware registers or memory, Assembly or C might be more appropriate. For web based applications, a language like JavaScript might be best.