Tuesday, November 24, 2026
HomeC ProgrammingForms of Programming Languages: Paradigms, Ranges, Examples

Forms of Programming Languages: Paradigms, Ranges, Examples


Write a * a + b * b in C, Java and Python and also you get three very various things. GCC turns it into ten bytes of x86-64 machine code. The Java compiler turns it into eight bytecode directions that settle for solely integers. Python turns it right into a handful of bytecode directions that may attempt to multiply no matter they’re given. The syntax barely differs; what occurs to the code does, and that’s what the kinds of programming languages describe.

This information covers the 5 methods languages are labeled: by degree, by paradigm, by how they run, by how they test sorts and by how they handle reminiscence. Each comes with actual code and actual output, together with one small process written in 5 paradigms. Each program was compiled or run for this text on Ubuntu 24.04: C with GCC 13.3 and Clang 18.1, C++23 with g++ 13.3 and clang++ 18.1, Java with OpenJDK 21, Python 3.15.0, Haskell with GHC 9.4.7, SQL on SQLite 3.45, Prolog on SWI-Prolog 9.0.4, JavaScript on Node.js 22 and Rust 1.97. The compiled packages construct with warnings enabled and no warnings, besides the place a warning is the purpose, and each output block is captured verbatim.

The Brief Reply

What are the primary kinds of programming languages? By degree, there are three: machine code, meeting language and high-level languages. By paradigm, there are 5 predominant types: procedural, object-oriented, purposeful, declarative and logic. Lists of “three sorts” or “4 sorts” are often utilizing one among these two classifications.

Is there one appropriate classification? No. A language has a spot on a number of impartial axes without delay. C is high-level, procedural, compiled to machine code, statically and weakly typed and makes use of guide reminiscence administration. Python differs from C on 4 of these 5.

Which classification issues while you select a language? Normally not the paradigm. How a language runs, the way it checks sorts and who frees reminiscence resolve its velocity, its security and the type of bugs you’ll spend time on.

What Is a Programming Language?

A programming language is a proper language with precise guidelines for writing directions a pc can perform. A compiler, an interpreter or each translate these directions into machine code, the binary directions a processor executes. Languages differ in how shut they sit to the {hardware} and in how they arrange code, run, test sorts and handle reminiscence.

The phrase “formal” issues. A programming language has a grammar with no ambiguity, so the identical supply code at all times means the identical factor. That’s the reason English, nonetheless exact, shouldn’t be a programming language, and why instruments that flip plain English into code nonetheless produce code in an atypical language corresponding to Python or C.

Not each pc language is a programming language. HTML and CSS describe paperwork and their look however can’t categorical a basic computation; TIOBE’s index definition excludes HTML for precisely that purpose, because it requires a language to be Turing full. SQL is a borderline case: it’s a question language, however normal SQL with recursive queries can categorical any computation, and it seems in most programming language rankings.

How Programming Languages Are Labeled

There isn’t a single taxonomy. 5 impartial questions cowl nearly each classification you’ll meet:

Axis The query it solutions Most important sorts
Degree How shut is the code to the {hardware}? Machine code, meeting, high-level
Paradigm How is a program organized? Procedural, object-oriented, purposeful, declarative, logic
Execution How does the code run? Compiled to machine code, bytecode on a digital machine, interpreted
Typing When and the way strictly are sorts checked? Static or dynamic; robust or weak
Reminiscence Who frees reminiscence that’s now not wanted? Guide, rubbish collected, possession checked by the compiler

Most actual languages are blended on at the very least one axis. C++ and Python assist a number of paradigms, Java is compiled to bytecode after which compiled once more whereas it runs and TypeScript provides static sorts to a dynamically typed language. Determine 1 locations C and Python on every axis.

5 methods to categorise a programming language Each language has a spot on every axis. Badges present the place C and Python (CPython) sit. Degree How near {hardware}? Machine code Meeting Excessive-level, techniques C Excessive-level, summary Py Paradigm How is the code organized? Procedural Py C Object-oriented Py Purposeful Py Declarative Logic Execution How does it run? Native machine code C Bytecode on a VM Py Interpreted supply Typing When and the way strictly? Static, weak C Static, robust Dynamic, weak Dynamic, robust Py Reminiscence Who frees reminiscence? Guide C Rubbish collected Py Possession, checked at compile time C Python (CPython) Different languages: see the desk later within the article
Determine 1: 5 methods to categorise a programming language. Each language has a spot on every axis; the badges present the place C and Python sit.

Low-Degree vs Excessive-Degree Languages

The oldest classification types languages by how a lot of the {hardware} they expose.

  • Machine code (additionally known as machine language, or a first-generation language) is the binary directions a processor executes straight. Every processor household has its personal: x86-64 machine code doesn’t run on an ARM chip.
  • Meeting language (second technology) provides every machine instruction a readable title, corresponding to imul for integer multiply. An assembler interprets it one to at least one into machine code. It’s simply as particular to at least one processor household.
  • Excessive-level languages (third technology and later) describe computations by way of variables, features and knowledge buildings. A compiler or interpreter interprets them, so the identical supply can run on completely different processors.

You may watch the interpretation occur. Here’s a one-line C perform:

// sq..c - one small C perform, to check with its meeting and machine code.
int square_sum(int a, int b)
{
    return a * a + b * b;
}

GCC at -O2 turns it into 4 meeting directions (gcc -O2 -fcf-protection=none -S -masm=intel, directives eliminated; with out -fcf-protection=none, Ubuntu’s GCC provides a 4-byte endbr64 safety instruction at first):

square_sum:
	imul	edi, edi
	imul	esi, esi
	lea	eax, [rdi+rsi]
	ret

The assembler turns these into machine code. objdump reveals the bytes subsequent to every instruction:

0000000000000000 <square_sum>:
   0:	0f af ff             	imul   edi,edi
   3:	0f af f6             	imul   esi,esi
   6:	8d 04 37             	lea    eax,[rdi+rsi*1]
   9:	c3                   	ret

The entire perform is ten bytes. The primary three, 0F AF FF, are what the processor reads as “multiply register edi by itself”. No person writes packages in hex bytes any extra, and few folks write complete packages in meeting; it survives in working system kernels, bootloaders, hand-tuned math libraries and code that should use a particular processor instruction. Meeting language nonetheless ranks seventeenth within the November 2026 TIOBE Index, and studying it’s a routine a part of debugging and optimizing compiled code.

One C perform at three ranges GCC 13.3 at -O2 on x86-64. Every degree is a translation of the identical perform. Excessive-level language: C Meeting language Machine code (hex bytes) int square_sum(int a, int b) { return a * a + b * b; } imul edi, edi 0F AF FF imul esi, esi 0F AF F6 lea eax, [rdi+rsi] 8D 04 37 ret C3 gcc as What the processor reads for the primary instruction (imul edi, edi): 00001111 10101111 11111111 Complete perform: 10 bytes
Determine 2: One C perform as high-level supply, because the 4 meeting directions GCC produces at -O2 and because the ten bytes of machine code the processor runs.

Is C a middle-level language? You’ll usually see C and C++ known as “middle-level”. It’s a casual label, not a separate sort. By the usual definition C is a high-level language: it’s transportable and compiled, and the identical supply runs on any processor with a C compiler. It earns the nickname as a result of its operations map intently onto machine directions, as the instance reveals, and since it permits you to work with reminiscence addresses straight.

You might also meet fourth-generation (4GL) and fifth-generation (5GL) languages. The phrases date from the Seventies and Nineteen Eighties: 4GL meant languages that describe what outcome you need, corresponding to SQL and report mills, and 5GL meant languages that clear up issues from constraints, corresponding to Prolog. They’re higher described in the present day by their paradigm, which is the following classification. For the way the generations happened, see the historical past of well-known programming languages and their authors.

Programming Paradigms: One Job, 5 Methods

A programming paradigm is a method of organizing a program: what this system is fabricated from and the way it will get from enter to outcome. The clearest technique to see the distinction is to unravel one drawback in every fashion.

The duty: given 5 orders, add up the quantities of the orders price 100 or extra. The reply is 570 (120 + 300 + 150).

Crucial and Procedural: C

An crucial program is a sequence of steps that change this system’s state, often the values of variables. Procedural programming is crucial programming organized into procedures, or features. C, Pascal, Fortran and Go are primarily procedural.

// orders.c - crucial, procedural fashion: step-by-step directions
// that change variables, grouped right into a perform.
#embrace <stdio.h>

struct order {
    const char *buyer;
    int quantity;
};

int total_large_orders(const struct order *orders, int rely, int minimal)
{
    int complete = 0;
    for (int i = 0; i < rely; ++i) {
        if (orders[i].quantity >= minimal)
            complete += orders[i].quantity;
    }
    return complete;
}

int predominant(void)
{
    const struct order orders[] = {
        {"Ada", 120}, {"Linus", 45}, {"Grace", 300}, {"Ken", 80}, {"Bjarne", 150},
    };
    const int rely = (int)(sizeof orders / sizeof orders[0]);

    printf("Orders of 100 or extra: %dn", total_large_orders(orders, rely, 100));
    return 0;
}

Output:

Orders of 100 or extra: 570

The perform says how to get the reply: begin a complete at zero, take a look at every order in flip, add the quantity whether it is massive sufficient. The variable complete modifications on each matching step. That is the closest of the 5 types to how the processor itself works, which is one purpose procedural code is straightforward to observe and straightforward to make quick.

Object-Oriented: Java

An object-oriented program is fabricated from objects that maintain knowledge along with the strategies that work on it. Callers ask an object to do one thing as a substitute of reaching into its knowledge. Java, C#, Kotlin and Smalltalk are constructed round objects; C++, Python and JavaScript assist them alongside different types.

// Orders.java - object-oriented fashion: knowledge and the conduct that makes use of it
// stay collectively in objects, and callers work by means of their strategies.
import java.util.ArrayList;
import java.util.Listing;

public class Orders {
    report Order(String buyer, int quantity) {
        boolean isAtLeast(int minimal) {
            return quantity >= minimal;
        }
    }

    static class OrderBook {
        personal closing Listing<Order> orders = new ArrayList<>();

        void add(String buyer, int quantity) {
            orders.add(new Order(buyer, quantity));
        }

        int totalAtLeast(int minimal) {
            int complete = 0;
            for (Order order : orders) {
                if (order.isAtLeast(minimal)) {
                    complete += order.quantity();
                }
            }
            return complete;
        }
    }

    public static void predominant(String[] args) {
        OrderBook guide = new OrderBook();
        guide.add("Ada", 120);
        guide.add("Linus", 45);
        guide.add("Grace", 300);
        guide.add("Ken", 80);
        guide.add("Bjarne", 150);
        System.out.println("Orders of 100 or extra: " + guide.totalAtLeast(100));
    }
}

Output:

Orders of 100 or extra: 570

The loop inside totalAtLeast continues to be procedural. What modified is the place the code lives. The record of orders is personal to OrderBook, every Order decides for itself whether or not it’s massive sufficient and predominant by no means touches the record straight. That construction pays off as a program grows, as a result of the foundations for an order sit in a single place. The object-oriented programming information covers courses, encapsulation, inheritance and polymorphism intimately.

Purposeful: Haskell

A purposeful program builds its outcome by making use of and mixing features, with out altering variables. Information is immutable: as a substitute of updating an inventory, you produce a brand new one. Haskell is solely purposeful; Lisp, Clojure, Elixir, F# and OCaml are purposeful first, and most fashionable languages have borrowed purposeful options.

-- orders.hs - purposeful fashion: no variable is modified; the result's
-- constructed by composing features (map, filter, sum) over immutable knowledge.
knowledge Order = Order String Int   -- buyer, quantity

quantity :: Order -> Int
quantity (Order _ a) = a

orders :: [Order]
orders = [Order "Ada" 120, Order "Linus" 45, Order "Grace" 300, Order "Ken" 80, Order "Bjarne" 150]

totalAtLeast :: Int -> [Order] -> Int
totalAtLeast restrict = sum . filter (>= restrict) . map quantity

predominant :: IO ()
predominant = putStrLn ("Orders of 100 or extra: " ++ present (totalAtLeast 100 orders))

Output:

Orders of 100 or extra: 570

totalAtLeast has no loop and no variable that modifications. It’s three features joined by . (perform composition), learn from proper to left: take every order’s quantity, hold those of at the very least restrict, add them up. As a result of nothing is modified, the perform at all times returns the identical outcome for a similar enter, which makes purposeful code straightforward to check and protected to run in parallel.

Declarative: SQL

A declarative program describes the outcome you need and leaves the steps to the language’s engine. SQL is probably the most broadly used declarative language; HTML, CSS, common expressions and construct recordsdata corresponding to Makefiles are declarative too, although they don’t seem to be general-purpose programming languages. Purposeful and logic programming are additionally counted as declarative types.

-- orders.sql - declarative fashion: describe the outcome you need;
-- the database decides find out how to discover it.
CREATE TABLE orders (buyer TEXT, quantity INTEGER);
INSERT INTO orders VALUES ('Ada', 120), ('Linus', 45), ('Grace', 300), ('Ken', 80), ('Bjarne', 150);

SELECT 'Orders of 100 or extra: ' || SUM(quantity)
FROM orders
WHERE quantity >= 100;

Output (sqlite3 :reminiscence: < orders.sql):

Orders of 100 or extra: 570

The question says what: the sum of quantity over the rows the place quantity >= 100. It says nothing about loops, order or indexes. The database chooses find out how to discover the rows, and with an index on quantity it could select in a different way with none change to the question.

Logic: Prolog

A logic program states info and guidelines, then asks questions. The language searches for each reply that makes the foundations true. Prolog is the best-known logic language; Datalog, an easier relative, is used inside some databases and code-analysis instruments.

% orders.pl - logic fashion: state info and guidelines, then ask a query.
% Prolog searches for each reply that makes the rule true.
order(ada, 120).
order(linus, 45).
order(grace, 300).
order(ken, 80).
order(bjarne, 150).

large_order(Buyer, Quantity) :- order(Buyer, Quantity), Quantity >= 100.

predominant :-
    findall(Quantity, large_order(_, Quantity), Quantities),
    sum_list(Quantities, Complete),
    format("Orders of 100 or extra: ~w~n", [Total]),
    findall(Buyer, large_order(Buyer, _), Prospects),
    format("Positioned by: ~w~n", [Customers]).

:- initialization(predominant, predominant).

Output (swipl orders.pl):

Orders of 100 or extra: 570
Positioned by: [ada,grace,bjarne]

There isn’t a perform that computes the entire. large_order is a rule: an order is massive if it exists and its quantity is at the very least 100. findall asks Prolog for each Quantity that satisfies the rule. The second query reuses the identical rule to ask one thing else, which clients positioned massive orders, with no new code. Operating a rule “backwards” like that is what units logic programming aside.

Multi-Paradigm Languages: C++

A multi-paradigm programming language helps a number of programming types and allows you to combine them in a single program. C++, Python, JavaScript, Rust, Kotlin and Scala are all multi-paradigm. Hottest languages in the present day are, which is why “which paradigm is that this language?” usually has multiple reply.

C++ can clear up the identical process 3 ways in a single file:

// orders.cpp - a multi-paradigm language: the identical process 3 ways in C++.
#embrace <algorithm>
#embrace <iostream>
#embrace <numeric>
#embrace <ranges>
#embrace <string>
#embrace <vector>

struct Order {
    std::string buyer;
    int quantity;
};

// Object-oriented: a category retains its knowledge personal and exposes conduct.
class OrderBook {
public:
    void add(std::string buyer, int quantity) { orders_.push_back({std::transfer(buyer), quantity}); }
    int total_at_least(int minimal) const
    {
        int complete = 0;
        for (const Order& o : orders_)    // procedural loop inside a way
            if (o.quantity >= minimal)
                complete += o.quantity;
        return complete;
    }
    const std::vector<Order>& orders() const { return orders_; }

personal:
    std::vector<Order> orders_;
};

int predominant()
{
    OrderBook guide;
    for (auto [name, amount] : {std::pair{"Ada", 120}, {"Linus", 45}, {"Grace", 300}, {"Ken", 80}, {"Bjarne", 150}})
        guide.add(title, quantity);

    // 1. Object-oriented name (with a procedural loop inside).
    std::cout << "OOP technique:      " << guide.total_at_least(100) << 'n';

    // 2. Purposeful fashion: a pipeline of views, no variable is modified.
    auto massive = guide.orders() | std::views::rework(&Order::quantity)
                               | std::views::filter([](int a) { return a >= 100; });
    std::cout << "ranges pipeline: " << std::ranges::fold_left(massive, 0, std::plus<>{}) << 'n';

    // 3. Generic programming: one algorithm for any container and predicate.
    const auto& v = guide.orders();
    std::cout << "std algorithm:   "
              << std::accumulate(v.start(), v.finish(), 0, [](int sum, const Order& o) {
                     return o.quantity >= 100 ? sum + o.quantity : sum;
                 })
              << 'n';
}

Output:

OOP technique:      570
ranges pipeline: 570
std algorithm:   570

The category is object-oriented, the loop inside it’s procedural, the C++20 ranges pipeline is purposeful (nothing is modified till fold_left provides the values) and std::accumulate is generic programming: one algorithm that works with any container and any rule. The fundamentals of C++ explains how these types match collectively within the language.

All six packages print 570. Right here is how the paradigms examine:

Paradigm A program is Modifications state? Instance languages Sturdy at
Procedural Steps grouped into features Sure C, Go, Pascal, Fortran Pace, simplicity, techniques code
Object-oriented Objects that mix knowledge and strategies Sure, inside objects Java, C#, C++, Python Massive packages with many associated sorts
Purposeful Capabilities utilized to immutable knowledge No Haskell, F#, Elixir, Clojure Information transformation, concurrency, testing
Declarative An outline of the outcome Not visibly SQL, HTML, CSS, common expressions Queries and configuration
Logic Info, guidelines and questions No Prolog, Datalog Guidelines, search, constraint issues

Compiled, Interpreted and Bytecode Languages

The third classification is about how code runs. There are three predominant fashions:

Mannequin How the code runs Typical languages Commerce-off
Compiled forward of time Translated to machine code earlier than it runs C, C++, Rust, Go, Swift Quick begin and execution; construct per platform
Bytecode on a digital machine Compiled to bytecode, which a VM runs and sometimes compiles to machine code whereas working (just-in-time, or JIT) Java, Kotlin, C#, Python One construct runs anyplace the VM does
Interpreted from supply Learn and executed straight, assertion by assertion Shell scripts, early BASIC No construct step; slowest

Strictly, it is a property of a language’s implementation, not of the language. There are C interpreters and ahead-of-time compilers for Java and C#, and a few Python implementations use a full JIT compiler. The labels describe the standard means a language is run.

Java’s compiler produces bytecode for the Java Digital Machine. Right here is identical a * a + b * b perform after javac, proven with javap -c:

public class Sq. {
    static int squareSum(int a, int b) {
        return a * a + b * b;
    }
}
  static int squareSum(int, int);
    Code:
       0: iload_0
       1: iload_0
       2: imul
       3: iload_1
       4: iload_1
       5: imul
       6: iadd
       7: ireturn

Eight directions, and imul and iadd are integer multiply and add: the kinds had been mounted when the code was compiled. When this technique runs usually, the JVM’s JIT compiler turns it into native machine code very like the C model.

Python is often known as interpreted, however CPython compiles each perform to bytecode first and interprets the bytecode. The dis module reveals it:

import dis

def square_sum(a, b):
    return a * a + b * b

dis.dis(square_sum)

Output (Python 3.15.0):

  3           RESUME                   0

  4           LOAD_FAST_BORROW_LOAD_FAST_BORROW 0 (a, a)
              BINARY_OP                5 (*)
              LOAD_FAST_BORROW_LOAD_FAST_BORROW 17 (b, b)
              BINARY_OP                5 (*)
              BINARY_OP                0 (+)
              RETURN_VALUE

RESUME is setup; the work is six directions. The important thing distinction from Java is BINARY_OP 5 (*). It’s a generic multiply that decides at run time what * means for the values it receives, so the identical bytecode multiplies integers, floats or anything that helps *. That flexibility is a big a part of why CPython is slower than Java or C for quantity crunching. CPython has shipped an experimental JIT compiler since Python 3.13; in Python 3.15, launched in October 2026, the discharge announcement places it at about 7 to eight% quicker than the usual interpreter on x86-64 Linux (geometric imply).

Yet one more goal price figuring out is WebAssembly, a transportable bytecode that browsers and different runtimes execute at near-native velocity. C, C++, Rust and Go compile to it, and WebAssembly 3.0, accomplished in September 2025, added rubbish assortment assist that makes it a sensible goal for Java, Kotlin and Dart as properly.

The selection of compiler issues for compiled languages too; the information to the finest C++ compilers compares GCC, Clang and MSVC.

Static vs Dynamic, Sturdy vs Weak Typing

Typing is 2 separate questions which can be usually confused:

  • Static or dynamic: are sorts checked when this system is compiled or whereas it runs? In a statically typed language, each variable has a kind the compiler is aware of. In a dynamically typed language, values have sorts however variables don’t, and mismatches are discovered when the code runs.
  • Sturdy or weak: does the language refuse to combine sorts, or convert one into one other silently? There isn’t a strict definition, however the distinction reveals up clearly in follow.

The identical mistake, including a quantity to a string, in 4 languages:

// combine.c - C is statically however weakly typed: "52" + 1 is pointer arithmetic,
// so it compiles and silently skips the primary character.
#embrace <stdio.h>

int predominant(void)
{
    printf("[%s]n", "52" + 1);
    return 0;
}

Output:

[2]

C is statically however weakly typed. A string literal is an array, "52" + 1 is pointer arithmetic, and this system prints the string beginning at its second character. It compiles, runs and is mistaken for those who meant to append. GCC 13.3 compiled it with -Wall -Wextra -pedantic and gave no warning. Clang 18.1 did warn:

combine.c:7:27: warning: including 'int' to a string doesn't append to the string [-Wstring-plus-int]
    7 |     printf("[%s]n", "52" + 1);
      |                      ~~~~~^~~
combine.c:7:27: observe: use array indexing to silence this warning
    7 |     printf("[%s]n", "52" + 1);
      |                           ^
      |                      &    [  ]
1 warning generated.
// combine.js - JavaScript is dynamically and weakly typed: values are transformed.
console.log("5" + 2);
console.log("5" - 2);
console.log("5" * "2");

Output:

52
3
10

JavaScript is dynamically and weakly typed, and it converts values to make an expression work. + with a string means concatenation, so "5" + 2 is "52". - and * haven’t any string that means, so the identical strings develop into numbers and the outcomes are 3 and 10. Three operators, two conversion guidelines: that is the basic supply of JavaScript bugs, and the primary purpose TypeScript exists.

# combine.py - Python is dynamically however strongly typed: no silent conversion.
print(int("5") + 2)
print("5" + 2)

Output:

7
Traceback (most up-to-date name final):
  File "combine.py", line 3, in <module>
    print("5" + 2)
          ~~~~^~~
TypeError: can solely concatenate str (not "int") to str

Python is dynamically however strongly typed. It won’t guess: you change explicitly with int("5"), otherwise you get a TypeError. However the error seems solely when that line runs. This system printed 7 first, and a line that by no means runs in testing can carry the error into manufacturing.

// combine.rs - Rust is statically and strongly typed: the error is a compile error.
fn predominant() {
    let complete: i32 = "5" + 2;
    println!("{complete}");
}

Compiler output (rustc combine.rs):

error[E0369]: can't add `{integer}` to `&str`
 --> combine.rs:3:26
  |
3 |     let complete: i32 = "5" + 2;
  |                      --- ^ - {integer}
  |                      |
  |                      &str

error: aborting as a result of 1 earlier error

For extra details about this error, attempt `rustc --explain E0369`.

Rust is statically and strongly typed: the error is a compile error, and no program is produced.

The run-time timing of dynamic typing is less complicated to see with a perform. Right here is square_sum from earlier, known as 3 times in Python:

# dynamic.py - one Python perform, three argument sorts. Varieties are checked
# whereas this system runs, when an operation is definitely tried.
def square_sum(a, b):
    return a * a + b * b

print(square_sum(3, 4))
print(square_sum(1.5, 2))
print(square_sum("3", 4))

Output:

25
6.25
Traceback (most up-to-date name final):
  File "dynamic.py", line 8, in <module>
    print(square_sum("3", 4))
          ~~~~~~~~~~^^^^^^^^
  File "dynamic.py", line 4, in square_sum
    return a * a + b * b
           ~~^~~
TypeError: cannot multiply sequence by non-int of sort 'str'

The primary two calls work, with integers and with a float, as a result of Python checks sorts solely when * is definitely utilized. The third fails contained in the perform. In Java the third name wouldn’t compile.

Typing Weak (converts silently) Sturdy (refuses to combine)
Static (checked at compile time) C, C++ Rust, Java, C#, Go, Haskell, Swift
Dynamic (checked at run time) JavaScript, PHP, Perl Python, Ruby

Deal with the robust/weak column as a spectrum. C++ is stricter than C, Java converts numbers to strings while you use + with a string and PHP 8 rejects extra blended operations than earlier variations did. Static typing can be creeping into dynamic languages: TypeScript for JavaScript and sort hints checked by instruments corresponding to mypy for Python.

Reminiscence Administration: Guide, Rubbish Collected and Possession

The fifth axis has develop into probably the most debated one. Each program allocates reminiscence; the query is who provides it again.

Mannequin Who frees reminiscence Languages Price
Guide The programmer, with free or delete C, C++ (with RAII and good tips that could automate it), meeting Quick and predictable; errors trigger crashes and safety holes
Rubbish collected A runtime that finds and frees unreachable objects Java, C#, Go, JavaScript, Python, Haskell Secure; makes use of additional reminiscence and a few CPU time
Reference counted Freed when the final reference disappears Swift, Goal-C; Python alongside its collector Predictable; cycles want additional dealing with
Possession The compiler proves when reminiscence may be freed Rust Secure and quick; stricter guidelines to be taught

Guide reminiscence administration is the place C and C++ get their velocity and their best-known bugs: use after free, double free and buffer overflows. US companies have been pushing trade towards memory-safe languages for a number of years. Joint steering from CISA, the NSA and worldwide companions in 2023 named C#, Go, Java, Python, Rust and Swift as examples, and CISA and the NSA revealed a joint information on adopting memory-safe languages in June 2025. C++ is responding from inside: C++26, whose technical work completed in March 2026, provides a hardened normal library mode and turns studying an uninitialized variable from undefined conduct into “inaccurate conduct”. Trendy C++ already avoids most guide delete calls, because the C++ reminiscence administration information reveals.

Common-Goal, Area-Particular and Scripting Languages

Two extra labels describe what a language is for:

  • Common-purpose languages can be utilized for nearly something: C, C++, Java, C#, Python, Go, Rust.
  • Area-specific languages (DSLs) are designed for one job: SQL for databases, R for statistics, MATLAB for numerical work, Verilog for {hardware}, GLSL for graphics shaders. They try this job with far much less code than a general-purpose language would want.
  • Scripting languages are general-purpose or near-general-purpose languages used to automate duties and glue different packages collectively: Bash, PowerShell, Python, Perl, Lua. The time period describes how a language is used, not a technical property; Python is a scripting language in a construct script and an utility language in an online service.
  • Markup and elegance languages, HTML, XML, Markdown and CSS, describe construction and look. They’re pc languages however not programming languages.

Right here is the place frequent languages sit on each axis. “Normally runs as” describes the primary implementation.

Language Degree Most important paradigms Normally runs as Typing Reminiscence
Meeting Low Crucial Assembled to machine code Untyped Guide
C Excessive (techniques) Procedural Native machine code Static, weak Guide
C++ Excessive (techniques) Procedural, object-oriented, generic, purposeful Native machine code Static, weak Guide, automated with RAII
Rust Excessive (techniques) Procedural, purposeful, generic Native machine code Static, robust Possession
Go Excessive Procedural, concurrent Native machine code Static, robust Rubbish collected
Swift Excessive Object-oriented, purposeful, protocol-oriented Native machine code Static, robust Reference counted
Java Excessive Object-oriented, purposeful JVM bytecode with JIT Static, robust Rubbish collected
Kotlin Excessive Object-oriented, purposeful JVM bytecode with JIT Static, robust Rubbish collected
C# Excessive Object-oriented, purposeful .NET bytecode with JIT Static, robust Rubbish collected
Python Excessive Procedural, object-oriented, purposeful CPython bytecode Dynamic, robust Reference counted plus collector
JavaScript Excessive Prototype-based objects, purposeful, event-driven JIT-compiled by the engine Dynamic, weak Rubbish collected
TypeScript Excessive Identical as JavaScript Compiled to JavaScript Static (sorts eliminated when compiled) Rubbish collected
Haskell Excessive Purely purposeful Native machine code Static, robust, inferred Rubbish collected
SQL Excessive (declarative) Declarative Inside a database engine Declared column sorts Managed by the database
Prolog Excessive (declarative) Logic Compiled to an summary machine Dynamic Rubbish collected

Reputation will depend on what you measure. The TIOBE Index for November 2026, which counts search engine outcomes for every language, places Python first at 20.86%, then C (11.48%), Java (8.89%), C++ (8.35%) and C# (3.39%). The 2026 Stack Overflow Developer Survey, which asks builders what they really use, places JavaScript first at 62%, adopted by SQL, HTML/CSS and Python at about 58% every, with Rust rising to twelfth.

The 2 lists disagree as a result of they measure various things, however collectively they present that each sort on this information is in heavy use. Procedural C and multi-paradigm C++ sit close to the highest of TIOBE, the declarative SQL close to the highest of the survey and the dynamically typed Python and JavaScript on the high of each.

Select a Sort of Language

Begin from the job, then let the job choose the kind:

  • Working techniques, embedded gadgets, recreation engines and performance-critical libraries: compiled techniques languages, C, C++ or Rust.
  • Internet entrance ends: JavaScript, or TypeScript for static sorts on high of it.
  • Information evaluation, machine studying and automation: Python, with SQL for the information itself.
  • Massive enterprise functions and Android: Java, Kotlin or C# on a garbage-collected runtime.
  • Studying how computer systems work: a language near the {hardware} teaches probably the most. That’s the argument for studying C as a primary programming language.

Studying one language from a second paradigm is price greater than a 3rd language from the identical one. Somebody who is aware of C and Python understands much more of the desk above than somebody who is aware of Java and C#.

Key Takeaways

  • Languages are labeled on 5 impartial axes: degree, paradigm, execution mannequin, typing and reminiscence administration. Each language has a spot on every.
  • By degree there are three sorts: machine code, meeting and high-level languages. One line of C grew to become 4 meeting directions and ten bytes of machine code.
  • By paradigm there are 5 predominant types: procedural, object-oriented, purposeful, declarative and logic. All 5 solved the identical process and obtained the identical reply, 570, in very completely different shapes.
  • Hottest languages are multi-paradigm. C++ solved the duty 3 ways in a single program.
  • “Compiled” and “interpreted” describe implementations. Java and Python each compile to bytecode; Java’s bytecode fixes the kinds, Python’s decides them at run time.
  • Static vs dynamic and robust vs weak are completely different questions. C (static, weak) accepted "52" + 1 and GCC didn’t warn; Python (dynamic, robust) refused "5" + 2 however solely when the road ran.
  • Reminiscence administration is now a security query, with authorities steering pushing new code towards memory-safe languages.

Steadily Requested Questions

Conclusion

The kinds of programming languages are much less a set of packing containers than a set of trade-offs. Nearer to the {hardware} means extra velocity and extra duty; static sorts catch errors earlier at the price of extra ceremony; rubbish assortment and possession take away an entire class of bugs that guide reminiscence administration invitations. Seen that means, a “new” language is never new: it’s a completely different place on axes you already know.

The quickest technique to make these variations actual is to jot down the identical small program in languages from two or three completely different columns of the desk above and examine what every one makes you consider. Extra language guides and tutorials are within the programming part.

What I Verified

Each instance on this article was compiled or run on Ubuntu 24.04 (x86-64) on 22 November 2026. The captured outputs had been regenerated by one script earlier than the article was assembled.

Verify Consequence
C examples, GCC 13.3 and Clang 18.1, -std=c17 -Wall -Wextra -pedantic -Werror Constructed with no warnings; combine.c constructed with out -Werror, since its Clang warning is the purpose
C++ instance, g++ 13.3 and clang++ 18.1, -std=c++23 -Wall -Wextra -pedantic -Werror Constructed with no warnings
Java (javac -Xlint:all -Werror, OpenJDK 21), Haskell (ghc -Wall -Werror, GHC 9.4.7) Constructed with no warnings
SQL (SQLite 3.45), Prolog (SWI-Prolog 9.0.4), Python 3.15.0, Node.js 22, Rust 1.97 Run; outputs captured verbatim, file paths eliminated
Identical outcome from all paradigm packages 570 from C, Java, Haskell, SQL and Prolog, and from all three C++ variations
AddressSanitizer and UndefinedBehaviorSanitizer on the C and C++ order packages Clear
Machine code and meeting Captured from gcc -O2; Determine 2 is generated from that seize

Not coated: Home windows and MSVC, macOS, ARM processors (the machine code is x86-64 solely) and different variations of the compilers and runtimes listed. Bytecode listings specifically change between Java and Python variations.

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments