[HN Gopher] A Programming Language Database
       ___________________________________________________________________
        
       A Programming Language Database
        
       Author : breck
       Score  : 130 points
       Date   : 2022-08-27 14:52 UTC (8 hours ago)
        
 (HTM) web link (github.com)
 (TXT) w3m dump (github.com)
        
       | doug-moen wrote:
       | The PLDB documents "over 4000 programming languages". I suspect
       | this is well short of the true number.
       | 
       | "... today... 1,700 special programming languages used to
       | 'communicate' in over 700 application areas." -- Computer
       | Software Issues, an American Mathematical Association Prospectus,
       | July 1965.
        
       | damagednoob wrote:
       | JSON[1] is a programming language?
       | 
       | [1]: https://pldb.com/languages/json.html
        
         | tadfisher wrote:
         | It has a restricted grammar and can be parsed, so it is a
         | programming language as much as any on the list. It just
         | doesn't have a canonical runtime.
        
           | oreilles wrote:
           | A programming language is a notation for writing programs,
           | which JSON isn't, not more than any other storage format or
           | markup language.
        
           | avgcorrection wrote:
           | CSV too?
        
           | Someone wrote:
           | I doubt many share your opinion that anything with a
           | restricted grammar that can be parsed is a programming
           | language.
           | 
           | I think your definition is closer to, if not identical to,
           | what Wikipedia calls "Computer Language"
           | (https://en.wikipedia.org/wiki/Computer_language)
           | 
           | For me, and I think for most, the more restricted https://en.
           | wikipedia.org/wiki/Programming_language#Definitio... ("A
           | programming language is a notation for writing programs,
           | which are specifications of a computation or algorithm") is
           | closer to what makes a formal language a programming
           | language.
        
           | still_grokking wrote:
           | Any arbitrary string of Unicode characters would be a
           | programming language given that above definition. Which makes
           | of course no sense.
           | 
           | A syntax without predefined runtime semantics is not a
           | programming language!
           | 
           | Without the interpretation semantics no (or every, depending
           | on standpoint) computation can be described by any syntax.
           | The definition of runtime semantics for some syntax is what
           | creates a programming language in the first place.
           | 
           | Pure syntax OTOH can be given _arbitrary interpretations_. So
           | it 's therefore not a programming language on its own. The
           | runtime semantic of some code is what allows us to write and
           | execute programs.
           | 
           | One can't write even the most trivial programs in JSON. No
           | "Hello World" as JSON does not offer any I/O facility. No
           | "fizzbuz" as there are no control structures or any loops in
           | JSON. No "Fibonacci numbers" as there are no function
           | abstractions in JSON...
           | 
           | JSON is just not a programming language.
           | 
           | (Still a valid candidate to include in computer language
           | collection, of course, as JSON has its merits regardless the
           | fact there is no canonical way do write in it anything that
           | resembles computer programs).
        
         | jenscow wrote:
         | https://pldb.com/pages/about.html
         | 
         |  _PLDB is a comprehensive database of programming languages and
         | their features. The focus is on programming languages, but the
         | database also includes other languages and entities one degree
         | away--from popular high level plain text formats to binary
         | specifications and beyond._
        
           | damagednoob wrote:
           | So is this none of one those 'increasingly ill-named' type of
           | things. I guess it's easier to include everything then to try
           | and define what is and isn't a programming language.
        
         | satiric wrote:
         | I'd say so - same as HTML or CSS. It may not be Turing complete
         | but it's a language used for programming computers.
        
           | oreilles wrote:
           | These can only be used to describe and format documents, not
           | to write programs, which is why they are markup languages and
           | not programming languages.
        
             | diroussel wrote:
             | JSON Schema has an 'if' construct. That gives JSON a
             | standardised way to do flow control.
             | 
             | I'm still not sure I would call it a programming language.
             | But I wouldn't say it's not one.
        
               | oreilles wrote:
               | JSON can be used to write an abstract syntax tree of a
               | program, but the specific grammar used and the way of
               | converting it into a program would be the programming
               | language, not JSON itself.
        
             | still_grokking wrote:
             | Well, modern HTML + CSS is actually Turing-complete.
             | 
             | https://stackoverflow.com/questions/2497146/is-css-turing-
             | co...
             | 
             | You can't have any programming language that is more
             | powerful than that. So technically speaking (HTML + CSS) is
             | a "proper programming language". Just a very awkward one
             | where the user has to "operate the crank on the machine" to
             | execute it.
        
               | oreilles wrote:
               | It's turing complete "so long as you consider user
               | interactions to be part of the "execution" of CSS". So
               | no, it cannot be used to write computer programs.
        
               | still_grokking wrote:
               | First comment to accepted answer:
               | 
               | > The formal definition (simplest) of Turing Machine is
               | simply a tuple of states set, symbol set, initial state,
               | accepting states set and a transition function. _There is
               | no crank in it._ By computation we mean somebody needs to
               | apply the transition function faithfully on the tape
               | which is exactly like the clicking in this case. More
               | formally, a model of computation can be viewed as a set
               | of rules somebody needs to follow to do the computation.
               | In that sense, I think CSS is Turing-Complete. - Shuhao
               | Tan Jun 11, 2018 at 21:32
               | 
               | [Emphasis mine]
        
             | [deleted]
        
         | xtagon wrote:
         | Maybe not pedantically, but it's a language relevant to many
         | programmers. Seems useful to include it. They include other
         | syntaxes such as HTML too.
        
         | pulse7 wrote:
         | This is not only a list of programming languages, but a list of
         | "technologies". To get only programming languages you have to
         | filter on type=pl [1]. JSON is marked with type=dataNotation
         | [2] - so it is a "data notation" language...
         | 
         | [1] https://pldb.com/lists/languages.html?filter=pl
         | 
         | [2] https://pldb.com/lists/languages.html?filter=dataNotation
        
       | ossopite wrote:
       | This site reminds me of http://rigaux.org/language-study/ which
       | includes studies of where language concepts originated, lineage
       | of languages, wide ranging syntax comparison (although missing
       | some newer languages) and other interesting things
        
       | ksherlock wrote:
       | So the first blog entry I randomly looked at:
       | 
       | https://pldb.com/posts/does-every-programming-language-suppo...
       | 
       | is about line comments. C gets credit for the // comments,
       | starting in 1972, but that's not really accurate. BCPL -- which
       | begat B which begat C -- had // comments but they were not
       | included in C until C99. C++ (which isn't included in their top
       | 30 languages) brought back // comments from BCPL sometime between
       | 1979 and 1985 (the first public release of cfront). Many C
       | compilers included // comments as an extension prior to C99 but
       | those were inspired by C++.
        
         | breck wrote:
         | Very interesting and helpful context. Thanks ksherlock!
         | 
         | I've updated that post a bit with some of your info:
         | https://github.com/breck7/pldb/commit/fb3a46baee0fe06218884e...
        
         | doug-moen wrote:
         | CPL (the direct ancestor of BCPL) also had a form of `//`
         | comments. Quoting from the manual:
         | 
         | > A comment is introduced by a double bar and continues up to
         | the end of that line; the whole of this text is ignored.
         | 
         | The double bar was written as `||`.
         | 
         | This information comes from the "CPL Working Papers", July
         | 1966.
        
         | Stratoscope wrote:
         | This brought back a vivid memory. Sometime in the late 1980s
         | there was a C standards committee meeting in the San Jose area,
         | leading up to the C89 standard.
         | 
         | I was acquainted with one of the committee members and called
         | him to ask if // comments would be included in the standard.
         | 
         | He told me there was no plan for this, but if it was something
         | I felt strongly about, I would be welcome to visit the
         | committee meeting and lobby for it.
         | 
         | I thought about doing this, but didn't bother since all the C
         | compilers I was using already supported // comments.
         | 
         | Memory is a funny thing. I don't remember the committee
         | member's name or exactly when I called him, but I could tell
         | you exactly where I was sitting and which direction I was
         | facing when we talked. I also think it was before I got
         | married, so that would put the call perhaps sometime in 1987.
         | 
         | Any old-timers here happen to know when that meeting was?
        
           | scythe wrote:
           | And thus, Lua's source code gained a kilobyte worth of */
        
         | barkingcat wrote:
         | isn't c++ at place #5 on https://pldb.com/lists/top500.html ?
        
           | ksherlock wrote:
           | d'oh you're absolutely correct. And it's in the blog
           | infographic.
        
       | nerdponx wrote:
       | Missed opportunity to encode this as s-expressions or a Prolog
       | database!
        
         | cyberbanjo wrote:
         | I don't know enough Prolog to know why you'd want that (please
         | share), but SWI prolog has a SQL interface to run prolog over
         | SQL data, and the author has released it as CSV and JSON, I
         | know SQLite lets you import CSV data, probably other databases
         | do.
         | 
         | JSON to s-expr's should be convertable with simple search-and-
         | replace, or you could just load the file with a json library
         | with reader macros so it loads the data into the appropriate
         | data structures, I'm fairly sure both common lisp and clojure
         | let you read jsons directly like that.
        
           | rscho wrote:
           | SWI is full of features and does JSON and SQL on its own very
           | easily.
        
         | abiloe wrote:
         | If you view source, it is encoded in an s-expression
         | equivalent.
        
       | simonw wrote:
       | The CSV file at https://pldb.com/pldb.csv is served with open
       | CORS headers:                   Access-Control-Allow-Origin: *
       | 
       | This means you can open it in web apps like my Datasette Lite
       | application, so you can run SQL queries against it in your
       | browser:
       | 
       | https://lite.datasette.io/?csv=https://pldb.com/pldb.csv#/da...
       | 
       | Here's a more interesting query:
       | https://lite.datasette.io/?csv=https://pldb.com/pldb.csv#/da...
        
       | culi wrote:
       | This is pretty cool! I've thought about making something similar
       | myself. Nice to know I can contribute to something instead of
       | creating it from scratch.
       | 
       | Top programming languages since 2005:
       | 
       | - Go
       | 
       | - Swift
       | 
       | - Rust
       | 
       | - TypeScript
       | 
       | - Clojure
       | 
       | - Kotlin
       | 
       | - Julia
       | 
       | - PowerShell
       | 
       | - Elixir
       | 
       | - Dark
       | 
       | - F#
       | 
       | - CoffeeScript
       | 
       | - Crystal
       | 
       | - Nim
       | 
       | - Elm
       | 
       | - CUDA
       | 
       | - Reason
       | 
       | - Haxe
       | 
       | - Node.js (!)
       | 
       | - fish
       | 
       | - Zig
       | 
       | - Arduino
       | 
       | - Red
       | 
       | - Idris
       | 
       | - Vala
        
       | xhevahir wrote:
       | Does anyone here remember a website, active about ten years ago,
       | that had languages ranked according to statements like, "I feel
       | like I'm not smart enough to program in this language," and,
       | "This language has good support for concurrency?" There was
       | another ranking for different martial arts, IIRC. I don't
       | remember the name of the site and can't find any references to it
       | anywhere.
        
         | e3bc54b2 wrote:
         | Perhaps this one?[0]
         | 
         | It doesn't match exact description and I also have vague memory
         | of something similar, but not able to find it right now. Drew's
         | post does a reasonably snarky job though :)
         | 
         | 0: https://drewdevault.com/2019/09/08/Enough-to-decide.html
        
           | xhevahir wrote:
           | I'll have to read that. I seem to remember the page having
           | orange elements like HN's, and the language rankings were
           | displayed in tables. I thought it was a really good idea,
           | although I have no idea when or how the initial survey was
           | conducted. The ranking was pretty comprehensive both in the
           | range of questions and the number of languages (although
           | you'd have to wonder how many respondents had any experience
           | with languages like Io or Oz.)
        
         | timbit42 wrote:
         | It sounds like you are referring to a website called "The
         | Hammer Principle" formerly hosted at hammerprinciple.com. The
         | website went down shortly after the owner had collected all the
         | data they wanted.
         | 
         | I collected a bunch of the data in a spreadsheet in March 2014
         | before the website went down. It covered 51 programming
         | languages and 15 statements about them such as:
         | 
         | * Easy to tell what code does
         | 
         | * Language is expressive
         | 
         | * Code is very readable
         | 
         | * Code written is elegant
         | 
         | * I enjoy using this language
         | 
         | * I choose to use this language
         | 
         | * I would like to write more
         | 
         | * I can be sure code is correct
         | 
         | * This is a high level language
         | 
         | * Code is easy to maintain
         | 
         | * Encourages reusable code
         | 
         | * It is easy to write efficient code
         | 
         | * Code tends to be efficient
         | 
         | * Code tends to be reliable
         | 
         | * This language is good for teaching children
        
           | xhevahir wrote:
           | Yes! That's the one!
        
           | breck wrote:
           | Interesting! https://web.archive.org/web/20170412144310/http:
           | //www.hammer...
        
             | timbit42 wrote:
             | Looks like it was online longer than I thought and had a
             | lot more questions added after March 2014.
        
       | maynard_f wrote:
        
       ___________________________________________________________________
       (page generated 2022-08-27 23:00 UTC)