this post was submitted on 23 Oct 2023
164 points (91.4% liked)

Programming Humor

2504 readers
2 users here now

Related Communities [email protected] [email protected] [email protected] [email protected]

Other Programming Communities [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected]

founded 1 year ago
MODERATORS
 
top 14 comments
sorted by: hot top controversial new old
[–] [email protected] 18 points 10 months ago

HTML is a programming language in the same way that Taco Bell is Mexican food.

[–] [email protected] 8 points 10 months ago (1 children)

I did not think this was a hotly debated topic but, if you're going to call HTML a programming language then you probably aren't far from calling CSS a programming language and that is not a reality I'm willing to accept.

[–] [email protected] 6 points 10 months ago (1 children)

But CSS is a programming language: https://notlaura.com/css-is-a-programming-language/

The video presentation version of this is lots of fun too: https://youtu.be/dtddBM8s7xY

[–] [email protected] 4 points 10 months ago

Ty for this. Good read

[–] [email protected] 5 points 10 months ago (3 children)

A programming language is a set of instructions written by a programmer to deliver instructions to the computer to perform and accomplish a task.

By that definition, HTML is a programming language.

[–] [email protected] 15 points 10 months ago (1 children)

HTML is an initialism for HyperText Markup Language. It's purpose is to provide structure to data and cannot perform logic, the defining feature of programming languages.

[–] [email protected] -1 points 10 months ago (1 children)

I guarantee you that the people writing that HTML isn’t a language are the junior devs that use DIVs for everything in their structure, especially actionable elements like buttons or anchors. Let’s ignore that the “DIV is the element of last resort”, as per the html spec. Also, I doubt that anyone suggesting CSS isn’t a language hasn’t picked up a OReilley’s manual on it recently - 1100+ pages, before you get to the glossary. HTML & CSS are quite a powerful combination.

[–] [email protected] 1 points 10 months ago

HTML adds structure to data and CSS adds visual styling to HTML data. The only way to make that data interactive, or have it perform other complex tasks is with Javascript. JS is a scripting language which is a subset of programming languages.

Buttons, links, etc only move you from one piece of data to another via the browser. HTML cannot and does not perform any actions itself.

[–] [email protected] 8 points 10 months ago (1 children)

HTML is not trying to accomplish a task but specifically displaying stuff on the screen. Like a word document, or a jpeg.

[–] [email protected] 3 points 10 months ago (1 children)

HTML is not trying to accomplish a task but specifically displaying stuff on the screen.

But what if my task is to display stuff on the screen?

[–] [email protected] 2 points 10 months ago

Then you would be a rendering engine, built from a language that isn't HTML.

[–] [email protected] 5 points 10 months ago (2 children)

Is it Turing complete though? That's normally the real test

[–] [email protected] 7 points 10 months ago

CSS+HTML is Turing complete but not html alone.

[–] [email protected] 0 points 10 months ago

Magic the Gathering is Turing complete but nobody's calling it a programming language. Expressiveness and purpose are probably more important for calling something a programming language.