Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Obligatory cloc reading to see which implementations were shortest:

    -------------------------------------------------------------------------------
    Language                     files          blank        comment           code
    -------------------------------------------------------------------------------
    Rust                            17            294            155           3919
    C                               18            446            383           3356
    C#                              19            472            235           3314
    Visual Basic                    17            322            131           2945
    Java                            17            322            134           2872
    Go                              17            299            147           2636
    Bourne Shell                    16            304            241           2308
    Perl                            19            263            165           2167
    Haskell                         17            328             99           1951
    MATLAB                          25            176            114           1880
    Javascript                      23            263            145           1873
    PHP                             17            242            118           1791
    Scala                           16            219            113           1731
    Lua                             18            227             87           1715
    Python                          18            218            143           1393
    Ruby                            17            165             87           1219
    OCaml                           15            105             98           1154
    Clojure                         17            247            117           1011
    CoffeeScript                    17            193            126            989
    CSS                              6            150            132            792
    make                            26            233             59            580
    HTML                             1             17             27            227
    C/C++ Header                     6             47              9            172
    Maven                            1              2              7             72
    -------------------------------------------------------------------------------
    SUM:                           380           5554           3072          42067
    -------------------------------------------------------------------------------


Apparently Maven is uniquely suited for writing a LISP!


Or at least, describing the project for one.

https://github.com/kanaka/mal/blob/90ab31710e9a495ba3aebf794...

The Maven, HTML, C headers, and CSS are just support.


Forth is missing.

Personally I found Forth implementation the most impressive, even more so than bash. Well, Make comes close :)


Hm, I guess clock doesn't support forth? I just ran `cloc .` from the root directory.


That chart (i.e. cloc) is actually missing 6 of the more interesting implementations:

- forth

- mal itself (e.g. self-hosting: all implementations can run this)

- miniMAL (Lisp interpreter in < 1024 bytes of JS)

- PostScript

- R

- Racket




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: