Re: Steps beyond "Hello World" program

From: Ben Measures (saint_abroadremove_at_removehotmail.com)
Date: 09/12/04


Date: Sun, 12 Sep 2004 16:11:48 GMT

Dan Tex1 wrote:
> From: "!Q" no_spam@null.org
>
>>If you want to prove a language is really a programming language you
>>need to prove that it is Turing complete. This means that you can
>>implement any Turing machine in that language (of course you must limit
>>the Turing machines to those that do not require an infinite tape).
>>
>>HTML is not a programming language because it is not Turing complete.
>>
>>For more information see: http://en.wikipedia.org/wiki/Turing-complete.
>
> I don't consider HTML a language because it can't and doesn't do the things
> that "conventional" languages do. To me... HTML is more like a glorified
> Font processor.

What about XSLT? In appearance it looks similar to HTML, and it doesn't
do the things that "conventional" languages do either.

> On the other hand... what REEEEALLLLY is a computer language???

It's a way to describe an algorithm.

> it doesn't matter whether HTML is a language or not. What matters is... when
> you have some type of a task to do, can HTML accomplish the task

This is the question. How do you know if it can or not? This is where
Turing-completeness comes in.

If it's Turing-complete you can implement any well-defined algorithm in
it. Furthermore, it can perform any calculation any other
Turing-complete language can.

HTML is not Turing-complete. Thus you know that there are algorithms
that cannot be implemented with it.

Strangely enough, XSLT /is/ Turing-complete. In knowing this, we also
know that we can implement any well-defined algorithm in it, and we can
perform any calculation any other Turing-complete language can (such as
C, Java, or C++).

Turing-completeness is so fundamental to computers that programmers
simply cannot ignore it as being something "for geeks".

-- 
Ben M.


Relevant Pages

  • Re: Steps beyond "Hello World" program
    ... >> Forth but excluding, say, Postscript, HTML, and XSL). ... "Turing-complete system" - it's neither a subset nor a superset. ... "programming language" some system that's not Turing-complete. ...
    (comp.programming)
  • Re: A case for HTML as a programming language
    ... I'm forced to do with HTML). ... A computer is a programmable finite-state machine, and a language ... The contradiction of runinng a TM program on a FSM leads to the problems ... C and VB are Turing-complete, ...
    (comp.programming)
  • Re: Quineless Turing-complete languages
    ... in certain Turing-complete programming languages. ... language L. (By "Turing complete" I mean that for every n ... f_n be the partial function from N to N computed by P_n. ...
    (comp.theory)
  • Re: If you were developing a database in Forth...
    ... language, one that provides some capabilities but mostly the same ... capabilities that other Turing-complete langauges provide. ... I didn't reduce Forth down to being just another Turing-complete ... I hope so-- your rationale sounds to me more like rationalization. ...
    (comp.lang.forth)
  • Re: A case for HTML as a programming language
    ... > C and VB are Turing-complete, whereas HTML isn't. ... That is *exactly* the usual distinction. ... All programming language can do this with ease. ...
    (comp.programming)