What is a Programming Language?

Khun Yee Fung, Ph.D.
Programming is Life
2 min readNov 13, 2023

--

This is a trick question. To answer this question, you need a definition of the word ‘programming’, and the word ‘language’.

It is not as easy as you might think. Programming is simply providing instructions to a computer to achieve what you think the instructions will achieve. That is not a sure bet as bugs happen. What is a language? Well, it is simply a set of well-formed notation to allow programming to happen. Generally you want it to be a generative one, as you really want a language that can be used to generate an infinite number of potential programs.

So, is HTML a programming language? It can be. As there is yet another thing we need to talk about. And that is Turing complete. What does that mean? It means any function that can be computed by a Turing machine can be specified by the language. Yet again, this can be tricky: a Turing machine has an infinite tape. All computers we have so far, is limited by the amount of storage you can provide to it at any one time. So, all computers we have right now are strictly speaking huge finite-state machines. But we usually ignore this, until one day you ran out of storage, and your computer crashes. But we don’t consider that. The number of states is generally big enough that we just say the modern digital computers are Turing machine equivalent. Close enough.

Is HTML a programming language or not? It is not if you define a programming language as needing to be Turing complete. It is if you don’t need that to happen.

How about SQL? Well, it turns out that SQL is Turing complete. Don’t believe me? Well, this is link to an article. https://blog.coelho.net/database/2013/08/17/turing-sql-1.html

--

--

Khun Yee Fung, Ph.D.
Programming is Life

I am a computer programmer. Programming is a hobby and also part of my job as a CTO. I have been doing it for more than 40 years now.