5 ms·
>Considering HTML a programming language People don't care for semantics. If you write it and it causes a PC to do something (even if it's just to show a websi
by coldtea 7y ago
>Considering HTML a programming language
People don't care for semantics. If you write it and it causes a PC to do something (even if it's just to show a website), it's a programming language. Doesn't need to have branching, variables, etc... (not to mention that HTML includes JS and CSS) print "hello world", <b>hello world</b>, same difference.
- kragen 7y agoIt's important to care for semantics in order to have a conversation that conveys information, which is necessary for having culture, so I will continue the semantics discussion you have started. Your proposed definition of programming languages includes, as I said, CSV, JPEG, Word, and URLs. Does that mean that anyone who snaps a photo on Instagram is a programmer? This does not seem to be in accordance with the usual meaning of the word "programmer". Is it "programming" to write a dunning letter in Word? It seems to me like a qualitatively different activity. Programming languages are all more or less equivalent; although they have a variety of paradigms, and although they are supplied with a variety of I/O facilities, you can program more or less precisely the same set of computations in all of them. Consider the differences between C, Forth, Smalltalk, Prolog, Fractran, Lisp, Brainfuck, Haskell, VHDL, amd64 machine code, and Malbolge: some of these do not even have branching or variables, but they are all programming languages; none of them can compute anything that any of the others cannot. The exception might be things like Turner's "Total Functional Programming", which excludes nonterminating computations without, he hopes, excluding much of practical interest; Excel, excluding the macro language, also has this limitation, but in Excel it is more onerous. By contrast, you can't compute so much as a polynomial or NAND in HTML. That is to say, you can't program at all in HTML. So HTML is not a programming language. English does not include Latin, although, e.g.†, phrases like "inter alia" and "et cetera" can be used in English, and it's not uncommon for an English sentence to quote a Latin motto. Similarly, HTML does not include JS and CSS, just as it does not include the URL specification, and Python does not include SQL or HTML; they are six separate languages. † exempli gratia
- 7952 7y agoIt is an abstract form that outputs something seperate and new. In that sense it is like a recipe or a knitting pattern. The artifact created by execution is distinct from the code. The code itself is valued by that output rather than its own intrinsic qualities. And this ability to generate something seemingly novel is what makes coding cool and useful. You can write a bunch of code and get something that has emergent properties. The things you mentioned are usually just data. They are the artifact. They are not generating anything distinct. There is only the data.
- kragen 7y agoEverything you said above is true of URLs, JPEGs, and Word documents (which are XML), too, except for the things that aren't true of HTML, namely, "this ability to generate something seemingly novel", and "You can write a bunch of code and get something that has emergent properties." (To some extent that's true of JPEG, but not HTML.) It is not true that URLs, JPEGs, and Word documents "are usually just data. They are the artifact. They are not generating anything distinct," although I concede that it's true of CSV files.
- username90 7y agoDo people write jpegs and word documents by hand in a text editor?
- kragen 7y agoYour question reminds me of when I first learned it was possible to write programs without line numbers. It took me a while to believe it. I suppose you don't think programs in Scratch, Flash, or Labview, or output from a compiler, are programs?
- coldtea 7y ago>Your proposed definition of programming languages includes, as I said, CSV, JPEG, Word, and URLs. And yet people don't call them "programming languages", while they do call HTML that -- so that even if HTML is not a programming language, there's still a not formally expressed difference that people can intuitively grasp with those other things... >By contrast, you can't compute so much as a polynomial or NAND in HTML. That is to say, you can't program at all in HTML. So HTML is not a programming language. You can't program most things in SQL either (not without some modern extensions that make it turing complete), but it is still considered a programming language... I understand your point that "tt's important to care for semantics in order to have a conversation that conveys information", but I'm of the (e.g. Wittgenstein-ian) school that what matters is not some original/holy definition, but the actual popular usage.