Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Criteria to determine if it's a programming language

What are the critera or the basic features required to tell that X or Y is (or is not) a programming language?

I've done some reading (Is HTML considered a programming language?, Turing complete, and others), and came to the conclusion that a language or a syntax has to be Turing complete to be considered a programming language. Is this correct? Is it enough?

And how do I determine if something is Turing complete? Are there any specific criteria?

Is having control-of-flow structures (conditional statements and loops) enough to be considered Turing complete?

like image 456
Jérôme Avatar asked Jan 31 '11 10:01

Jérôme


1 Answers

There exist programming languages which are not Turing complete. For some examples of non-Turing complete languages, take a look at: Practical non-Turing-complete languages?

An advantage of having a language that is non-Turing complete could for instance be that it might be sufficient to perform the tasks you need, while being simple enough to allow you to prove properties about your programs, which you could not otherwise prove. This could, for instance, be useful in cases where it's vital to know that the program will run without error.

What exactly constitutes a programming language is a bit vague, but one could say that it's a language in which you can express computations. If we look at HTML, you cannot create a document that computes anything; it merely tells the browser how the page is supposed to look. The important part to note is, it doesn't compute anything new.

It is, as Marcelo says, quite fuzzy.

As for determining if a language is Turing complete, I will refer you to this question: What are practical guidelines for evaluating a language's "Turing Completeness"?

like image 144
Sebastian Paaske Tørholm Avatar answered Sep 21 '22 14:09

Sebastian Paaske Tørholm