164

Example here:

What languages should I know if I'm interested in building web applications?

Yes, I understand that HTML and CSS are not Turing-complete. Yes, I understand that they are declarative, not imperative languages. But why are people always clubbed over the head with this pedantic (and arguably obvious) fact when they ask a question about these languages?

Robert Harvey
  • 198,589
  • 55
  • 464
  • 673
  • 34
    It only bugs me when people put it on their resume's. It's only worse is when they put jQuery next to JavaScript under "Language Experience:". – Josh K Dec 20 '10 at 00:01
  • 20
    It seems pretty obvious to me: If I need to figure how who to hire, or to who to assign to a particular task I need to know what skills they have. If the assignment involves implementing an algorithm I'm not going to give it to someone who only has a background in HTML/CSS. I'm not going to assign someone who only has a background writing command line C programs to writing a bunch of complex web pages that have to work on multiple browsers. I don't know if you've been in the position of hiring or managing people, but you do run into lot of folks who swear these tasks are interchangeable. – Charles E. Grant Dec 20 '10 at 06:36
  • 10
    Data is just dumb code and code is just smart data: http://stackoverflow.com/questions/871833/what-does-data-is-just-dumb-code-and-code-is-just-smart-data-mean – Christoffer Hammarström Dec 20 '10 at 12:58
  • See also: http://en.wikipedia.org/wiki/Talk:Programming_language – Christoffer Hammarström Dec 20 '10 at 15:11
  • 2
    Because it means that a herd of monkeys could eventually use them just as well as most web developers, maybe? :) Oh, and mostly just the fact that you just cannot use HTML/CSS to implement any business logic in your application/website, except for hard-coded page links for the workflows. – haylem Dec 20 '10 at 20:18
  • 15
    People are failing to comprehend the OP's question which in more blunt terms would be: "Why is it that a certain type of twit, in a discussion about generalized 'languages,' feels the need to point out that CSS isn't a programming language?" First of all, duh. Thank you. Anybody who knows even a modest handful of stupid JavaScript tricks is going to get that. Does mastery of CSS mean something to a programmer whose been there and mastered that? Oh yes. Yes it does. I don't care if we're programming the next Mars rover, it's a definite tie-breaker. – Erik Reppen Aug 12 '11 at 03:18
  • 7
    XSLT is an interesting case to think about in this context... – Dan Diplo Aug 12 '11 at 08:09
  • 1
    @Dan Diplo the distinction is that XSLT is turing complete – MattDavey Nov 11 '11 at 09:20
  • 1
    @MattDavey: Is someone a "real programmer" if XSLT all they know? – Robert Harvey Nov 11 '11 at 15:58
  • 3
    @Robert Harvey I hate to answer a question with another question but: Is someone a 'real carpenter' if hacksaw is all they know? – MattDavey Nov 11 '11 at 16:12
  • @MattDavey: My point exactly. – Robert Harvey Nov 11 '11 at 16:16
  • @Robert Harvey it seems we are in agreement :) – MattDavey Nov 11 '11 at 16:20
  • TeX is an interesting corner case. It's technically a programming language, but most people use it purely as a markup language. – CodesInChaos Feb 24 '13 at 09:40
  • 1
    `Why does it matter that a square is not a car`? You are begging the question. Perhaps it doesn't matter at all. Yes, HTML and CSS are not programming languages, but perhaps it doesn't really matter. – Thomas Eding Jun 07 '13 at 00:06
  • @ThomasEding It only matters to the pedants. – Robert Harvey Jun 07 '13 at 02:12
  • 1
    @JoshK As a JS/Frontend dev you *have* to put jQuery on your resume, if you want to get hired... It's on of those magic keywords employers want to read. – CunningFatalist Jan 13 '15 at 08:40
  • All comments or answers here miss an important point (sorry if I overlooked it being mentioned): It may have *legal* implications whether html and css are program languages. There are html and css files under GPL license. If these are considered *programs* rather than just *documents*, GPL's library linking clauses might apply if other pages frame, link or embed-link them. This would determine in what way GPL would virally apply to such linking pages. – stewori Feb 01 '22 at 19:52
  • Because we're nerds. It's what we do. – Martin Maat Mar 04 '23 at 09:08

12 Answers12

309

What is the difference, really?

The real and important difference between a programming language and these other languages is this:

HTML and CSS describe presentation, whereas programming languages describe function

I intend to illustrate why this difference matters, but that pedantry on this issue is sometimes misplaced.

A true story:

I once spent a few months developing a complex performance management system using a "proper" programming language. It automated the process of gathering data from various other systems, performed various manipulations on that data and then presented the results in a simple table.

Once it was live, a senior manager saw a tool written for a similar business, and asked if we could replace what I had written using their alternative. Furthermore, he was upset that I'd spent weeks developing my solution, where this new app had been written in a matter of days.

Further investigation revealed that the manager's preferred option was all presentation with no substance: there were lots of colours and icons and graphs, but there was absolutely no logic behind them. All the data had to be gathered and manipulated manually. Despite the pretty interface, the application was essentially useless.

I'm happy to say that the manager in question was persuaded that my approach was the one that met his real business needs.

The importance of presentation:

There is often an implication that skills in HTML, CSS etc. are somehow inferior to skills in "real" programming languages. This is a serious mistake.

In my story, the senior manager felt that design was very important to him, to the extent that he was initially prepared to overlook function in its favour. Now, if this were an isolated incident, I might suggest that the manager was just being silly. But it wasn't. Time and again, I've met users who are impressed by flashy graphics and whizzy widgets, but unimpressed by raw functionality and my technical achievements. I think that there are several lessons to learn here:

  • People evaluate software on criteria that they understand. They often understand the difference between good-looking and ugly, but rarely appreciate technical nuances.
  • People are fooled by appearances. This may not be a good thing, but it is a reality that we must live with.
  • Appearances influence the way people feel about software. The way people feel about software is important to them. Indeed, people sometimes prefer software that makes them feel good over software that is functionally superior. Indeed, they might well be more productive with feel-good tools than with technically superior tools. To this extent, our users are not being fooled. They are actually making a wise and thoughtful choice.
  • As programmers, we often neglect the role of presentation as we focus on function. To some extent, this is right and proper. However, it is important to recognize that there is another dimension to our work that is important to our customers.

So, presentation-oriented languages (HTML, CSS) are important. The value added by those who can use these tools effectively should not be underestimated.

The importance of real programming languages

As the OP pointed out, "real" programming languages are Turing Complete. As a proper sad geek, I find this sublimely fascinating. It means that, for any program written in a T-C language, a functionally equivalent program can be written in any other T-C language. Of course, this isn't to say that all languages are the same. They each have their strengths and weaknesses that make them more or less suitable for certain tasks. However, I/O aside, this means that all programs can be written in all true programming languages.

(Incidentally, the important thing is T-C. The declarative vs imperative is a red-herring here. SQL, for example, is declarative but is also a proper programming language because it is T-C.)

Of course, the same isn't true of a markup language like HTML or CSS. In fact, there are whole classes of problem that these languages simply can't solve. Where I can program anything I want in a true programming language - including layout engines - it just isn't possible to achieve the same things with languages that aren't T-C.

As highlighted in my story, HTML and its ilk are used to produce presentation. Real programming languages are used to produce functionality.

Why are programmers pedantic about it all?

  1. Programmers spend a great deal of time, effort and money developing their skills. People naturally value the things in which they invest ("your heart is where your money is").
  2. Programmers often feel the need to justify the amount of time it takes to produce results compared to the rapid results achieved by UI designers. In order to do this, they need to draw a distinction between what the two groups actually do.
  3. Because employers need to apply the right people to the right jobs. Unless we clarify the (often technical) differences, managers easily make the wrong calls.
  4. Because there is a real and fundamental difference, as outlined above.

Is it always appropriate to be pedantic?

Let's face it, as programmers we're a naturally pedantic lot. It goes with the territory. It doesn't help that many of us have been burned when non-programmers have failed to understand what we do.

Nevertheless (and to be honest, this goes against my natural instincts), I don't think we need to call people out whenever they slip over every little distinction.

The important things here are context and perspective.

I'm told that, from the perspective of a biologist, a tomato is a fruit. But when I buy them in the supermarket, I look for them amongst the vegetables. Why? Because the technical distinction doesn't matter in that particular context. Moreover, the distinction would actually get in the way of their usefulness: if I was daft enough to include tomatoes in a fruit salad, for example.

It is the same with computer languages. There are times when the difference between programming languages and other languages really does matter. Quite often, however, we can all communicate perfectly effectively when just lump them all in together. In the case of the question linked by the OP, it really didn't matter what languages were true programming languages and which were not. Pointing out the distinction didn't advance the discussion in any way. Thankfully, other than adding a little noise (and becoming the stimulus for an interesting discussion!) the pedantry linked by the OP was of little consequence. At its worst, however, pedantry can stir up negative feelings and damages relationships... at least according to my wife.
:-)

How to deal with pedantry amongst programmers

A preacher friend of mine once delivered a sermon entitled:

is this a hill worth dying to be on?

He was referring to generals who make a strategic assessment over which battles are worth fighting: are the gains worth the costs?

  • Is it really worth interrupting the flow of the discussion to make this distinction?
  • Does my pedantry stem from a sense of arrogance or from past hurt?
  • Do my comments value the skills of others as well as my own?

Of course, there are times when distinctions need to be made. My aim is that, when I make a contribution, it will add value to our collective endeavors.

That is, after all, the job of every real programmer.

Kramii
  • 14,029
  • 5
  • 44
  • 64
  • 4
    I didn't think SQL was Turing-complete, unless you're talking about T-SQL or PL/SQL. – FrustratedWithFormsDesigner Feb 23 '11 at 18:36
  • @FrustratedWithFormsDesigner: You're right! Thanks for picking me up on that. (However, the point I'm making stands - that declarative languages can be T-C) – Kramii Mar 03 '11 at 10:41
  • @Kramii, except that it is the imperative portions of T-SQL and PL/SQL that allow them to be turning complete. Neither is a purely declarative language. (Actually I consider PL/SQL a seperate procedural language with tight integration to Oracle's SQL, not an extension of SQL. Not everyone agrees with me, see comments to this question: http://stackoverflow.com/questions/3472937/regarding-date-in-sql) – Shannon Severance Aug 02 '11 at 22:43
  • 1
    Very good answers. As a web-developer I've seen over-and-over again situations where clients' are impressed far more with a "flashy" design than by proposed functionality. Whilst this may offend our purist programmer instincts (that functionality should be king) it is something we ignore at our peril. – Dan Diplo Aug 12 '11 at 07:59
  • 4
    +1: Joel Spolsky has an interesting blog post that takes up the problem with function vs flashy GUI. Especially the hazards of showing a 100% finished and very flashy GUI when the functionality is not in place. A good read if you havent read it. http://www.joelonsoftware.com/articles/fog0000000356.html – Leo Jan 25 '13 at 08:21
  • 3
    "They might well be more productive with feel-good tools than with technically superior tools" - True, true, true! Apple has built their business on this. Don't get me wrong, Mac has substance too, but what has made some people pay almost twice as much for a Mac machine as a Linux or Windows one is that it *looks* cool and it *feels* good to use. – GlenPeterson Jun 06 '13 at 14:20
  • from the perspective of a biologist, a tomato is a fruit. But when I buy them in the supermarket, I look for them amongst the vegetables. epic – ihebiheb May 05 '18 at 10:39
119

Tell a Civil or Mechanical Engineer that you studied "Software Engineering" and they'll tell you that "Software Engineering" isn't real engineering.

Tell an F-16 pilot that you fly Cessnas for fun and he'll tell you you're not a real pilot.

Tell a doctor that you're a chiropractor and he'll tell you... well, let's not go there :-)

I think it's mostly that people don't like the idea of their profession being infiltrated by pretenders or people who aren't really "worthy".

Now, to be fair, it's quite clear that HTML and CSS are not programming languages. They're no more programming languages that the .docx format is a programming language, and to claim that you're a programmer if all you know is HTML and CSS is certainly inaccurate. But I think some of the vehemence in the reply can be attributed to what I said above.

Also, in the question you linked, the questioner called HTML and CSS a "language", not a "programming language". HTML is a markup language and CSS is a language too (I don't know what "kind" of language you'd call CSS, though?), so I think it was a bit unfair to call him out for calling them "languages"...

Dean Harding
  • 19,871
  • 3
  • 51
  • 70
  • 7
    "I don't know what "kind" of language you'd call CSS, though?" - at a pinch "style description language" would do it. – ocodo Dec 20 '10 at 00:00
  • 1
    @Slomojo: yes, "description language" seems like a good one. Like "IDL" is "Interface description language" or WSDL is "Web Service description language" etc... – Dean Harding Dec 20 '10 at 00:31
  • i wouldnt call markup (or markdown) a language... –  Dec 20 '10 at 05:22
  • 29
    @acidzombie24: What does the "L" in "HTML" stand for? – Dean Harding Dec 20 '10 at 05:33
  • 10
    If it has syntax and semantics, then it's pretty hard to claim it's not a language. HTML and CSS are both languages by these criteria (as are English, Esperanto, Klingon, and arguably UML). None of them are "programming" languages, though. – Zach Dec 20 '10 at 08:02
  • 4
    The engineers and doctors would be right, though – even if for completely different reasons. Software engineering may *become* an engineering disciplin but it isn’t one yet, it’s much too immature for that. We’re still in a very early, experimental stadium of SE. As for chiropractics … systematic studies have pretty much shown that chiropractic is ineffective, and the alleged underlying mechanism is scientific nonsense that directly contradicts what we know of biology. – Konrad Rudolph Dec 20 '10 at 11:11
  • @Zach: What about file formats that uses text instead of binary? Or web protocols? would you consider them languages? Also @Dean Harding: i had a laugh thinking about this. American football is a sport that has no contact with your foot or a (classic sphere) ball –  Dec 20 '10 at 20:12
  • Well, software engineering really isn't engineering, so the analogy falls a bit short. There really is no such thing as software engineering. For now. – haylem Dec 20 '10 at 20:22
  • 2
    @acidzombie24 I think it depends on the text format, or on the protocol, but either could arguably be a language. Wikipedia defines language as "a set of symbols of communication and the elements used to manipulate them". Certainly HTML and CSS fit within that definition -- I'm not sure whether a text file format or web protocol would. – Zach Dec 20 '10 at 20:34
  • 7
    @Dean Harding - Hyper Text Markup Legos? – VirtuosiMedia Aug 12 '11 at 06:04
  • 4
    CSS is a DSL (Domain Specific Language) for describing style (i.e. it's domain is visual aesthetics) – Paul Aug 12 '11 at 08:00
  • @acidzombie24 Well occasionally we DO kick the ball in American Football, for kick offs, field goals and such. I just think it's silly we call that weird shaped thing a "ball." – Graham Aug 12 '11 at 13:55
  • @Graham exactly lol –  Aug 26 '11 at 03:05
  • @Dean: What Graham said. –  Aug 26 '11 at 03:05
  • @Slomojo, Why not "declarative language"? – Pacerier Jan 26 '16 at 17:14
  • No one said it wasn't, OP states this in their question. – ocodo Jan 27 '16 at 04:51
  • Any SR-71 pilot will tell any F-16 pilot that he/she is not a real pilot http://oppositelock.kinja.com/favorite-sr-71-story-1079127041 – Bent Sep 13 '17 at 14:38
10

It doesn't really matter to me so much.

But I presume that to those for whom it does, the distinction between HTML, CSS, XML, etc. and Real Programming Languages™ is kind of like the distinction between wood and paint as building materials. You can't build things with paint like you can with wood, and likewise you can't program with HTML like you can with an RPL.

I grant you though, for some conversations, making such a distinction can be irrelevant, and therefore pedantic and annoying.

Eric King
  • 10,876
  • 3
  • 41
  • 55
  • 1
    XML is a bad example because it's more general than HTML/CSS--XSLT is both XML and Turing-complete, for example. I think XML isn't really as much a language as just syntax--it specifies how tokens are defined but not what they mean. – Tikhon Jelvis Jan 09 '12 at 09:38
  • @TikhonJelvis I think we're basically saying the same thing, but while doing so you're proving my point. Splitting hairs as to whether XML (eXtensible Markup Language) is a "language" or a "syntax" is mostly irrelevant to the point as I was making, and therefore ... – Eric King Jan 10 '12 at 03:18
6

It matters to certain people because neither are rocket science on the surface but there is a great deal of arcana surrounding them due to the fact that they implement differently in typically 5 to dozens of different environments that you actually care about. That sort of unpredictability and attention to craft scares a certain variety of tech professional who is horrified by unquantifiable risks and even more horrified by learning anything more then they absolutely have to after securing a degree.

If somebody asked me what languages I knew and I threw CSS out there and they said "but that's not a REAL language" I would ask them how they would handle vertically centering a div in IE 5, IEs 6-8 and IE9+. Then we could move on to rounded corners, alpha transparency issues, the REAL culprit behind all these ridiculous tables-as-layout arguments that are only just now starting to be become truly irrelevant and dozens more topics for said uber-coder who probably knows one language and claims one or two that he's barely functionally literate in due to classes he was forced to take in college 10 years ago.

They definitely are 'languages.' I would not call them 'programming languages.' I would feel comfortable describing the process of writing in these languages 'coding.'

As far as I'm concerned, however, anybody who has managed to grand master CSS has the chutzpa and work ethic to become an excellent programmer, already has some background in object oriented thinking, and no doubt has learned to think about how what he writes now could impact his work 25 projects into the future.

Erik Reppen
  • 6,243
  • 31
  • 34
  • 3
    +1. I don't know how many times I've heard a "programmer" put down HTML/CSS as simple and not real programming. Then, when they can't figure how why their bulleted list only lines up properly in Firefox, they throw their hands up and declare that the whole Web is unsuitable for modern software :( – Graham Aug 12 '11 at 13:59
6

It might not be an "important" distinction, since arguably as much work goes in the html/css part of some websites as in the programming part.

But it is a significant distinction, since anybody that doesn't know what does it mean has no place in a team that does web development.

If a designer believes HTML is programming, let him stay designing with Adobe tools and do print-related designs; but don't believe a thing he might say about web apps.

If a developer thinks he's above designers because 'his' languages are Turing-complete, don't expect him to work well with designer, or that his code can be 'prettified' after it's done.

Javier
  • 9,888
  • 1
  • 26
  • 35
  • @Javier: What's your definition of a "programming language"? – Christoffer Hammarström Dec 20 '10 at 12:53
  • @Christoffer Hammarström: if pressed to give a formal definition, i'd go with Turing-completedness; but informally i just say that a program _does_ things, in response to some input. Usually, if there's no run-time `if ... then` construct and some way to repeat things a previously-unknown number of times, I'm inclined to say that it's not a programming language. Of course, there are some fringe languages that complicate definition; but HTML/CSS are **far** from that. – Javier Dec 20 '10 at 14:14
  • @Javier: Would you say that the canonical "Hello World" is a program, given that it takes no input? – Christoffer Hammarström Dec 20 '10 at 14:25
  • @Javier: According to a discussion on Wikipedia (http://en.wikipedia.org/wiki/Talk:Turing_completeness#good_non-turing_complet_language:_3D_shaders), early versions of Pixel Shader languages were not Turing-complete (no "generalised iteration capability", i.e. "some way to repeat things a previously-unknown number of times"). These were languages used only by programmers in programming the Graphics Processing Unit in popular games. Would you still say they were not programming languages? – Christoffer Hammarström Dec 20 '10 at 14:53
  • @Christoffer: Hello world requires input: you have to *initiate its execution.* Your observation about Pixel Shader is intriguing, though. – Robert Harvey Dec 20 '10 at 16:15
  • @Christoffer Hammarström: regarding hello world, it's just a degenerated example, doesn't say anything about the language (besides a little about syntax). Pixel Shader is one of those limiting cases that complicate formal definitions. I don't know the details, but it could be a case of something that's so technically complex that it's easiest for programmers to write. HTML was like that, before it became established enough to convince designers that they too need a text editor. – Javier Dec 20 '10 at 18:03
5

You hit it on the head when you said "declarative, not imperative". Markup (be it HTML, CSS, or whatever) describes things. The whole point of programming is to do things.

The skill set required to use markup is completely different than the skill set required to program.

The types of problems solved by writing markup are completely different from the types of problems solved by programming.

HedgeMage
  • 4,313
  • 1
  • 22
  • 28
  • 16
    Pure functional programming language are by their very nature declarative. So is Linq, Python’s list comprehension, XAML, XSLT, SQL and Prolog. All of which are bona fide programming languages and/or concepts. While *most* programming languages are imperative, this is **not** the defining feature. At all. – Konrad Rudolph Dec 20 '10 at 11:13
  • @KonradRudolph - If you think purely functional programming languages are in any sense declarative, you must not understand them very well. – Jonathan Cast Apr 21 '16 at 15:19
  • @jcast It’s entirely possible that I misunderstand something. But then so do the experts in the field, apparently; For a general reference, Wikipedia classifies (purely) functional programming languages as declarative. As a specific example, a Paul Bone, who has a PhD for work on pure declarative languages, also follows this definition. I’d be curious to know for what reason you take offence at the definition. – Konrad Rudolph May 04 '16 at 13:11
4

Programming language is a bit of an inexact term because it's a common term that is used by practitioners and the lay person as well. Practitioners have a nuanced meaning of that term where lay person usually doesn't. Normally their definition is if it has funny words/syntax that I don't immediately understand and programmers use it then that must be a programming language. Not completely off the mark, but we can agree it's inexact.

Words like declarative, imperative, and turing complete are more precise terms with very specific meanings. When you ask a question like why is HTML/CSS not a programming language you're asking for a more precise definition of what a programming language really is. We aren't being pedantic, but trying to answer your question. Are they the best terms to use when even if you google them it's hard to understand what they mean? Depends. Did you want the short or long answer. :-)

Programming languages are typically thought of being Turning-complete by programmers, but what does that mean? It means the language can describe behavior or how to do things. We formally call it logic. HTML/CSS can describe there is a button located in the top right corner, or there is a table with 4 columns 5 rows, first two rows are yellow, and the bottom row has green text, and each cell in the table has 5 pixels of blank space around the content.

What HTML/CSS can't do is express the behavior or logic of what happens when you click the button. It can't say when I click that button get the values out of that table and add them up, and write that value to a new row at the bottom of the table. Describing behavior is roughly equivalent to Turning-complete without getting overly pedantic.

More precisely Turing-complete means that you could implement the language in itself. That would mean I could write a javascript program that takes a string of javascript and it could execute it (and not using the eval() function). In fact, I can write a javascript program that could take a program written in any Turing complete language and evaluate it. That's what it means to be Turing complete. All languages that are Turning complete are equivalent in what programs can be expressed. Pretty amazing revelation if you think about it.

chubbsondubs
  • 664
  • 3
  • 6
  • *Turing-complete* means that the language can be used to simulate a Turing machine (or, it can calculate any Turing-computable function). – mipadi Dec 20 '10 at 16:10
  • 3
    @pipadi - A very correct and precise definition I will give you that, but someone asking questions like this are going to say "Well WTF is a Turing machine? WTF is a Turing-computable function?" If they don't understand Turing Complete are they going to understand Turing Machine or Turing-computable function either? It's like looking up the word rhetorical in the dictionary and it says "of, relating to, or concerned with rhetoric." That definition doesn't tell you what rhetorical actually means and just points you to another word you don't understand. – chubbsondubs Dec 20 '10 at 18:27
2

HTML and CSS are not programming languages. Get Over it.

However: JavaScript is a programming language. The machine is the browser. PHP is a programming language. The machine is a virtual one in the server.

So if you are doing only using HTML and CSS, you are not doing any programming (although you might be doing some engineering).

But if you are using JavaScript, PHP, or another scripting language. You ARE doing programming.

As for REAL programming languages. If you are operating on a machine (real one, or virtual). And are using YOUR OWN algorithms to tell the machine to do things. Then you are using a REAL programming language.

  • 6
    So I guess we can dispense with HTML, CSS and SQL because, after all, they're not *real* programming languages anyway. In fact, we might as well dispense with IDE's too, since any programmer worth his salt can make do with a command line editor. – Robert Harvey Dec 20 '10 at 00:04
  • 4
    I haven't downvoted this answer personally (I think -6 is enough!) but I would guess the reason for the downvotes is that this doesn't actually answer the question. The question is not "are HTML & CSS programming languages?", the question is "why does it matter?" – Dean Harding Dec 20 '10 at 00:29
  • 2
    @Robert Harvey... Command line editor!!! pah! and before someone pipes up about punch-cards, they're for wimps, real programmers toggle a single switch to enter all their code as raw binary, plus they do it when they sleep, which they do while jogging. – ocodo Dec 20 '10 at 01:14
  • @Robert Harvey: Your argument is highly ridiculous, just because something is essential to programming does not make it a language. HTML/CSS are not, IDEs are not. It is like arguing that because a knife is essential to food preparation it must itself be food. – Orbling Dec 20 '10 at 01:26
  • 1
    Not only doesn't it answer the question, it shows exactly the sort of pointless "I'm better than the HTML guy over there because I'm a *real* programmer" attitude that is so annoying with the comments about HTML and CSS not being a programming language. (Even if they are not, being good at HTML/CSS is damn hard and requires some serious hacker skills!) – Lennart Regebro Dec 20 '10 at 01:31
  • 6
    @Robert That's completely specious. "X is worthless" does not follow from Ricardo's argument that "X is not a Y". – Matthew Read Dec 20 '10 at 01:32
  • 4
    @Lennart Regebro @Robert Harvey: @Matthew Read's position is the nubbin of the conversation here - you are equating a feeling of superiority with a denial of a falsehood. HTML/CSS *is* exceptionally difficult, I hire people who can do it for me as I am no where near good enough at it, I lack the skills. It is a technical design skill, it is not *programming*. – Orbling Dec 20 '10 at 01:37
  • Well, that's your opinion, and your refusal to acknowledge than anyone could, and indeed has, a different opinion, must have some reason. I don't know you, but it's clear to me that most people who have dogmatic positions have it for emotional reasons, and in this case it's mostly because they want to feel a bit different and better than the HTML hackers. Which is why most people who have this dogmatic position are young guys who have just graduated from HTML hacking to "real" programming. – Lennart Regebro Dec 20 '10 at 01:45
  • @Orbling: `It is like arguing that because a knife is essential to food preparation it must itself be food.` -- It is more like me asking, "Should I put pepper on this steak," and you replying that I should have called it *black pepper.* I don't give a shit. I just want to know how to cook my steak, and *you already know what I meant.* – Robert Harvey Dec 20 '10 at 03:24
  • 1
    Programming is the implementation of math and logic to get the computer to accomplish an arbitrary task. Some programs, e.g. a word processor, require input to get the desired result -- some document. A browser is a program that takes input, e.g. an HTML web page, and uses it to generate the desired result -- what you see on the screen when you view a web page. The difference is fundamental. I see no reason to believe that writing HTML is any more "programming" than typing in a word processor is "programming". 95% of what you can do with those 2 things is the same. – Matthew Read Dec 20 '10 at 05:23
  • 3
    Making the word "programming" so broad is to make it nearly meaningless. The meaning is narrower than that, and you may well have a different opinion but it turns out that language means what the majority uses it to mean. – Matthew Read Dec 20 '10 at 05:25
1

The logical "left-brain" or creative "right-brain" pigeonhole/stereotype accurately describes many people's skill sets. In my experience, "is HTML/CSS a programming language" is more about whether people who are good at HTML/CSS can also be good at other programming tasks.

Most of the web designers I worked with in the last 13 years I've been doing web development have been able to create working HTML and CSS, but are not able to handle more demanding programming challenges (anything more than the simplest cut-and-pasted JavaScript). Most of the hot-shot programmers and database designers don't care enough about visual presentation to do a good job with HTML/CSS or presentation in general. Most actually refuse to try.

HTML and CSS require some programming skills: experimentation, problem-solving, careful testing, an understanding of inheritance... But they require at least an equal number of design skills: sensitivity to color, line, spacing, balance - most of the same kinds of visual composition skills that make a good photograph.

Since HTML/CSS is a layout or presentation language, it is at the end of the data flow diagram. No other code sits downstream of it. The larger-level design skills that someone needs in order to design a good API, service, or database schema are not used in HTML and CSS. There is generally no need to modularize anything HTML or CSS related, or if there is, it's not up to the graphic designer to do that. It is rare that any functionality is made with HTML/CSS. Drop-down menus are probably the most common exception, but they can be made by cutting and pasting a recipe off the web rather than by designing code.

It is unusual, but not impossible for a programmer to have some visual design or layout skills or for a designer to have some programming skills. These people are especially valuable on a web team because they help bridge a gap that most of us have. But they are often subject to stereotypes, that being able to do HTML/CSS is impossible for a "real programmer," or vice-versa. But this skill combination is no more impossible than for that same programmer to be a decent sailor, painter, cook, or to have some other skill that they practice in their spare time.

As other people have said, this distinction comes into focus most when hiring. Since people with crossover talents are rare, most job postings have to target one skill set or the other. If a programmer lists HTML/CSS under "Programming Languages" it raises a red flag that they can't accomplish general programming tasks, or that maybe their definition of programming is very narrow. Maybe they can, it just raises a question. If a designer lists HTML/CSS you definitely want to look at their portfolio to see that they have the artistic ability to create the desired visual effect.

HTML/CSS may be repeatedly trashed as not being real programming languages because it is safer and more socially acceptable than trashing people who can't cross the hemisphere divide that they represent. Of course, some people may not have that inhibition. I actually worked with one manager who often said, "He wrote [insert department backbone functionality here]? I thought he just did HTML?"

Great question!

GlenPeterson
  • 14,890
  • 6
  • 47
  • 75
1

Here's my two cents. HTML and CSS are clearly not programming languages. For that reason, when I see HTML or CSS on somebody's resume under "Programming Languages", that simply tells me that this person does not know what he is talking about.

Other than that, no, it does not really matter.

By the way, programmers generally tend to be pedantic. That simply comes with the job.

Dima
  • 11,822
  • 3
  • 46
  • 49
  • 4
    So in your mind there is no room for someone just being approximate about it because they don't want to waste space having another mark up language section? To me that's pedantry way beyond what's useful. – Jon Hopkins Dec 20 '10 at 12:08
  • 1
    +1 when i see a CV with HTML/CSS under 'programming', i read no further. either he doesn't know the difference (so he's no use for me), or hopes I don't know the difference (so i don't want to work with him) – Javier Dec 20 '10 at 14:22
  • @Javier: I understand that HTML and CSS are not programming languages, but to say that you can reasonably accomplish web "programming" without them is, to say the least, ridiculous. Frankly I'm a little surprised to hear that hiring supervisors really wish to be drawn into this kind of debate. – Robert Harvey Dec 20 '10 at 16:30
  • 2
    @Jon Hopkins: Attention to detail is a necessary quality in a programmer. Putting HTML under programming languages is not being approximate, it is being sloppy. That makes a very bad first impression if you are applying for a job as a programmer. – Dima Dec 20 '10 at 17:03
  • @Christoffer: A language that results in executable code, i. e. code that *does* something. Calling Latex a programming language is a stretch. Calling HTML a programming language is nonsense. But as I said, it generally does not matter, unless you are trying to get a job as a programmer. – Dima Dec 20 '10 at 17:07
  • @Robert Harvey: Fortunately, I am not a hiring supervisor. However I do get to look at people's resumes occasionally. – Dima Dec 20 '10 at 17:08
  • 1
    @Dima: absolutely. informality is ok, sometimes even in writing, imprecision in the very basic concepts of trade is unacceptable. – Javier Dec 20 '10 at 18:09
  • 1
    This is ridiculous. Resumes and interviews are one of the most problematic parts of our industry right now. You never know if someone who knows the difference still puts "HTML" under "Programming Languages" because they are scared some HR drone won't notice it under "markup/design/etc" and kicks out their resume. You should at least call them up or bring them in. If they tell you to your face that they "program in HTML," well... that's really a red flag. But then again, think of what you can accomplish now in HTML 5 alone! Is it really such a stretch? – Graham Aug 12 '11 at 14:04
  • 1
    @Graham: I would put HTML under "Technologies" together with things like MFC or WPF. Or I would have a section called "Languages" rather than "Programming Languages" to contain both programming languages and declarative or markup languages like HTML or XML. – Dima Aug 12 '11 at 15:50
  • @Graham: My point is that a resume is what makes the first impression on a potential employer. So it makes sense to take some care to present yourself in the best possible light. – Dima Aug 12 '11 at 15:52
1

I think it comes down to this - HTML & CSS, while complicated enough to require some savvy, are presentation languages, most suited as the format for generated reports. Therefore, people who can only do these were not considered coders. Bearing in mind that some coders have been in computing long enough to remember when the average word-processor took more command syntax to style text than HTML.

I will temper this with the note that gatekeeping by saying who is a "real" programmer and not is less than helpful. Encouraging people learning HTML and CSS into learning javascript and finding a world of more interesting flexibility is a better way. CSS has also become complicated enough that animations, composition and other concepts are present, and it's declarative style is similar to languages like HCL.

What some would call a 'real' language is that which would process data in some way to generate a report. Or something that could be used to write a game. Knowing HTML & CSS inside and out is a valuable skill, but it is much more so combine with knowledge of JS for front end, and Java, PHP, Perl, Ruby, Python, C/C++ or C# at the back end.

Conversely, someone who only knows one of those 'real' languages without any web front end technologies, are very much limiting their own flexibility as a coder.

Danny Staple
  • 469
  • 3
  • 8
  • I would suggest a language that is fully executed and run by a computer. I have debugged C code, and debugged CSS styles. I can say with some certainty that the latter can take as long (if not longer) than the former (depending on what horrible thing some person did with a pointer vs which obscure part of the spec you are trying to get working and *&^%$@ browser it looks wrong on). HTML alone does not really say much, but coupled with the full expression of CSS it can be plenty interesting. – Danny Staple Dec 20 '10 at 20:48
  • 2
    There is nothing worse than dealing with CSS and markup by devs who went into it thinking it would be child's play. – Erik Reppen Aug 12 '11 at 06:33
0

It doesn't matter. And it's also a matter of definition. What is a programming language? Some mean that it has to be Turing-complete. Others have other definitions, that make HTML a programming language. (And in your example, they weren't even called programming languages, just languages, which they obviously are).

My recommendation: Try to ignore people who point out these kinds of pointless and in many senses even incorrect claims. It's just a variation of grammar nazi-ism. Calling HTML a programming language isn't incorrect in any meaningful sense.

Lennart Regebro
  • 2,265
  • 13
  • 17
  • 7
    -1 It is meaningful as HTML is **not** a programming language, it does not have the basic elements of such a thing - it merely describes the layout on a page, by the same extension a book on technical drawing is a programming language. – Orbling Dec 20 '10 at 01:22
  • 1
    @Orbling: They are domain specific declarative programming languages according to the most common definitions of what that means. See for example: http://en.wikipedia.org/wiki/Declarative_programming#Domain-specific_languages So, sorry, you fail. According to perfectly common and sensible definitions, they *are* programming languages. And according to completely different, **but equally sensible and common definitions** they are not programming languages. Both views are correct. But the ones that whack their opinion over the heads of others are insecure and need to feel superior to HTML guys. – Lennart Regebro Dec 20 '10 at 01:28
  • 8
    The word "program" has a defined meaning that is generally agreed upon. You can't make a program with HTML, therefore making something with HTML is not "programming". Anyone who argues differently is arguing that the very words they use in their argument can have their meaning changed arbitrarily, and in that case I would arbitrarily assign their words to mean nothing. – Matthew Read Dec 20 '10 at 01:29
  • @Matthew Read: Excellently put. – Orbling Dec 20 '10 at 01:30
  • 1
    @Lennart Regebro: I do not regard HTML guys as inferior, I work with them day-by-day, they do their part, design and structural build/engineering, I do my part, programming. Neither group has any more or less respect for each other, both critical to the task, both highly skilled. One is programming, one is not. No value judgement. – Orbling Dec 20 '10 at 01:34
  • 1
    Programming is writing code to make the computer do something. You can do that with HTML. Yes, it is very *limited* as a programming language, but so is LOGO, which is generally accepted to be a programming language. Matthew: You claim that your definition is the One True Definition, yet people who know a lot of the issues does not always agree. How would you explain that? – Lennart Regebro Dec 20 '10 at 01:40
  • 4
    @Orbling: Is "I work with HTML guys" the new "one of my friends is {insert minority group here}"? – Anon. Dec 20 '10 at 02:32
  • 1
    @Lennart Regebro: Logo is a programming language, indeed one of my favourites (http://programmers.stackexchange.com/questions/21028/which-language-did-you-love-from-heart/21063#21063). A Data-Description-Language (DDL) is not a *programming* language, it controls nothing, just describes data in a structured form. – Orbling Dec 20 '10 at 02:41
  • @Anon.: LOL, sounds like it doesn't it? But genuinely I respect HTML builders, it is arguably harder than most programming tasks as HTML renderers vary in their interpretation of the data structure. Loads of bugs and obscurities everywhere in the older browsers, conflicting standards; it's bloody hard work. My head designer and I work together almost all day everyday uniting frontend and backend, indeed he and I came together to our current company from another as a pair, so integrated in our working practices are we. – Orbling Dec 20 '10 at 02:49
  • 1
    @Orbling: Yes, so you claim. Over and over and over, like it's God Own Truth. Even though it's been pointed out to you repeatedly that this is an opinion, and not everyone agrees. HTML and CSS in fact controls a lot of things. CSS is most obvious as it controls look and layout. Why is it, I wonder, programming of you write a javascript to reload a page every 5 seconds, but not programming if it's done in a HTML header? – Lennart Regebro Dec 20 '10 at 02:54
  • 2
    @Lennart Regebro, every standard definition of a programming language (even on Wikipeida) says that a programming language can describe an algorithm. How can you describe an algorithm in HTML and CSS? – Charles E. Grant Dec 20 '10 at 05:29
  • @Lennart 95% of people agree, that's why HTML is a "markup language" (it's in the name for crying out loud) and not a "programming language". If you want a general term for both, call them languages. Congratulations, doing HTML and doing C++ are both just writing language. Happy now? Or do you want to start arguing that C++ is a markup language, just to be fair? "people who know a lot of the issues does not always agree. How would you explain that?" The minority loses. Ever used a dictionary? Did you start arguing with the dictionary? – Matthew Read Dec 20 '10 at 05:32
  • Damn, this issue is really hitting some deep emotional territory. You just can't handle that there are people in the world who define "programming language" differently than you, can't you? These kinds of reactions is what you usually get when discussing religion and politics. Open up your mind, people! See the light! It's an OPINION! And it's not even mine! – Lennart Regebro Dec 20 '10 at 09:25
  • 1
    @Lennart: Okay, now tell me what kind of language C++ (or C, or Common Lisp, or whatever) is. This terminology should reflect the fact that it's a different sort of thing than HTML is, and it is used for entirely different purposes. Unless you can, then I think your opinion tends towards confusion in language, and therefore I think it a bad one. – David Thornley Dec 20 '10 at 18:40
  • C is an imperative programming language. C++ is imperative and object oriented. Both are also statically typed programming language. Lisp is a functional programming language. Python is an imperative object-oriented strong dynamically typed programming language. This is not a discussion about if a certain definition is "good" or "bad" but yours and others complete refusal of accepting that the definition even exists or have any validity whatsoever. – Lennart Regebro Dec 20 '10 at 18:50
  • 1
    @Lennart: No, it's a discussion of whether a definition is useful or not, and I fail to see where I'm completely refusing anything. I note that you use different terms for C and Lisp programming, removing the similarity, and getting into technical terms. I consider a taxonomy that separates C and Lisp, but not Prolog and HTML (both presumably declarative programming languages in your terminology) misleading and useless. As an exercise, try avoiding unfounded ad hominem arguments. It may make your points more clear. – David Thornley Dec 20 '10 at 20:58
  • No, that's what you are trying to discuss in an attempt of getting out of the corner. Yes, C and Lisp are different types of languages. The only similarity is that they are general purpose languages, which HTML is not, it's a domain specific language. This has been mentioned multiple times, but facts and arguments are obviously wasted here. You are wrong. Deal with it. – Lennart Regebro Dec 20 '10 at 22:02
  • My primary experience is front end web/UI development. I wouldn't call HTML or CSS programming languages. But I'd lose a lot more respect for somebody who rolled their eyes when somebody responded to the OPs question about 'languages' in general with a list that included CSS than I would some kid who listed CSS under programming languages on his resume. – Erik Reppen Aug 12 '11 at 03:06