75
Python
7y

At introduction of new class teacher asked which _one_ of the following isn't a programming language:
- Swift
- Pseudocode
- Haskell
- HTML

Took my chance on HTML, but apperantly pseudocode is less of a programming language according to him.

Comments
  • 66
    Psuedocode is a programming language. It's also called Python.
  • 4
  • 2
    Computerphile over at YouTube has made a video about that!
  • 17
    Unless something is Turing-complete, it isn't a programming language. It's pathetic.
  • 1
  • 1
    @Ashkin Hmm, I read somewhere that HTML (at least in combination with CSS, not sure) is Turing complete.
  • 4
    @21stCenturyJoku neither html nor css can do 1+1

    And don't say "but the <script> tag" because the content of that tag is not html
  • 5
    @inukinator I think this is what I remembered hearing about: http://jsfiddle.net/Camilo/eQyBa/
  • 1
  • 0
    @Ashkin I mostly agree, but... it also depends on how you define "Programming Language".

    Take primitive recursive functions: they can clearly be seen as a programming language. But any primitive recursive program always halt, so it is not Turing-complete.
  • 0
    @Pizza Sounds pretty pathetic 😉
  • 0
    Html with css can do some crazy stuff if you're set on using them for things they weren't designed to do, but no matter what you do they'll never be programming languages even when used together because they can't take their output as input. That is the only obstacle right now, and if they could do that they'd together be a fully fledged programming language.
  • 0
    @configurator Yup, that's what I got too reading through some discussions about it.
    But now I'm wondering: why can't you use CSS variables for this purpose? I never saw them mentioned while reading about the topic, is there a reason why?
  • 1
    Put both pseudocode and HTML get a point off for HTML and start a technical discussion with the teacher... and never give up!!! I have discussed over points for more than 90 min... AND WON! They're not up to date with their knowledge... ...and they god damn know!!!
    For every fight you take the next students have better exams just go for IT
  • 2
    @QueenMorgana You had a teaching job if I remember correctly... you teachers hate guys like me right?
  • 3
    @needToRoll I don't mind being wrong, but when more effort is put into arguing over points than the actual work, I have problems. Lol
  • 0
    @inukinator css does have "calc", which isnt js. Not sure if the makes it Turing complete.
  • 3
    @meowth
    Turing compete requires conditional branching and changing memory. E.g. if, goto, memset

    calc() cannot read from memory (other attribs), so it is irrelevant in this case.
  • 0
    @Ashkin I think calc can read --variables
  • 0
    @21stCenturyJoku that still doesn't allow for branching or loops.
  • 0
  • 1
    @kaesaecracker Yes but that's the version that still requires user input to trigger the next calculation. Whether that counts as Turing complete is debatable.
  • 0
    @21stCenturyJoku I'd say so: in this case the human is just a glorified Turing machine head mechanism 😛
  • 1
    Lol, I think I got exactly the same question wrong in college. Those were the times...
  • 0
    @kaesaecracker that article is sadly lacking in specifics ☹
  • 0
    I'm fairly sure turning completeness need not be what defines a programming language. Domain specific languages, like HTML don't require Turing completness. The most generic definition of a programming language is "a set of instructions for a computer."
  • 1
    It's in the name

    Hyper Text Markup Language

    It never claimed to be a programming language and never will be.

    It's the difference between taking your car to a body shop or a mechanic.

    The body shop makes it look good the mechanic makes it run good.

    As for those claiming it can be abused to act like a programming language: would you let a body shop service your engine?
  • 0
    @meowth if it can be Turing-complete, why shouldn't it be?

    CSS with functions, variables, nesting, etc. would be a serious improvement. There would be no need for Sass.

    Functions and variables in config files, markup, etc. would also be quite useful (though much more situational than the above)
  • 0
    @Ashkin not arguing for or against those features. I'm just saying that those features don't define language or not language. All a language needs to be is a set of instructions that a computer can process. Some systems benefit from constraint and certainly CSS and HTML cause loops and branching to occur in browsers.
  • 0
    @meowth fair enough. We're arguing two very different things then.
Add Comment