4 ms·
HTML is a declarative programming language. https://en.wikipedia.org/wiki/Declarative_programming#Domain-specific_languages https://en.wikipedia.org/wiki/Decla
by wormius 1y ago
HTML is a declarative programming language.
https://en.wikipedia.org/wiki/Declarative_programming#Domain-specific_languages https://en.wikipedia.org/wiki/Declarative_programming#Domain...
- kstrauser 1y agoNah. It’s a declarative language, but not a programming language. To prove me wrong, show an HTML program that does any kind of computation whatsoever. There’s not one. It’s not Turing complete. I doubt it’s even Turing partial. It’s a markup language, not a PL.
- rekenaut 1y agoWhere does this idea that a programming language has to be Turing complete come from? As far as I can tell from cursory searches, the most broadly understood understanding of a programming language is a formal language for directing computations on a computer. HTML does this, CSS does this, and SQL does this. Frankly even configuration languages like YAML or the spare INI file do this in the proper context. Can these languages do everything or even most computations you would be interested in doing in a computer? Of course not. But why should the definition be restricted to languages that can do everything?
- ctenb 1y agoYour definition is overly broad and makes everything a programming language, at which point the term isn't useful anymore.
- ngruhn 1y agoBut Turing completeness is also too broad. Otherwise Power point animations and Conways game of life are programming languages.
- ashirviskas 1y agoI will take this over HTML
- alkonaut 1y agoYes. So a criteria that is below Turing Completeness but which wouldn't make markdown a programming language. Shouldn't be _that_ hard to find such criteria. E.g. "Has some form of logic/flow control". Can perform computation/"execute". etc.
- gf000 1y agoI mean, CS is famously bad at exact definitions [1]. Why should we have one for what a PL is? Just do what humans have been doing for millenia, how is it commonly used. A tomato is a vegetable from a culinary perspective, and HTML is not a PL based on its use case and its literal name. [1] what is a low or high level language? Strongly typed language?
- jpardy 1y agoIs CSS included in the HTML, if so then it is turing complete, maybe? See: https://stackoverflow.com/questions/2497146/is-css-turing-complete https://stackoverflow.com/questions/2497146/is-css-turing-co...
- deleted 1y ago[deleted]
- brodo 1y agoIf HTML is a programming language, why not SVG? If SVG is a programming language, why not PNG? Is your image viewer just an interpreter executing PNG code? Maybe being a programming language is a spectrum...
- 1718627440 1y agoYes, if you go down this road then the equivalence of code and data means that everything is a programming language.