Programming Languages That Blew My Mind (2023)
The author reflects on their programming journey, emphasizing the impact of various languages like Opalang, which combines functional programming with simplicity, enhancing problem-solving skills and software design.
Read original articlethe combination of functional programming with a focus on simplicity and expressiveness. Opalang was designed to be a language that could handle complex applications while remaining accessible to developers. My experience with Opalang was transformative, as it allowed me to apply many concepts I had learned from other languages, such as type systems and concurrency models. The language aimed to provide a balance between power and usability, making it suitable for both novice and experienced programmers. Overall, my journey through various programming languages has not only shaped my skills as a developer but also influenced my approach to problem-solving and software design.
- The author reflects on their programming journey, highlighting languages that significantly impacted their understanding of coding.
- Key languages mentioned include Basic, Turbo Pascal, OCaml, Java, Prolog, and Erlang, each contributing unique concepts and paradigms.
- The author emphasizes the importance of learning from different programming languages to enhance problem-solving skills and software design.
- Opalang is noted as a special project where the author contributed as a lead designer, focusing on functional programming and accessibility.
- The article illustrates how exposure to diverse programming languages can lead to a deeper appreciation of software development.
Related
I Probably Hate Writing Code in Your Favorite Language
The author critiques popular programming languages like Python and Java, favoring Elixir and Haskell for immutability and functional programming benefits. They emphasize personal language preferences for hobby projects, not sparking conflict.
You should make a new programming language
Creating a programming language enhances understanding of design and execution, fosters creativity, and provides valuable insights. Implementing existing languages and choosing different implementation languages can deepen learning experiences.
You should make a new programming language
Creating a programming language enhances understanding of design and execution, encourages learning through initial flaws, and fosters creativity. Guided projects and resources support beginners in this fulfilling endeavor.
Gleam Is Pragmatic
Drew Olson discusses the Gleam programming language, which merges Haskell and OCaml features, supports immutable data, simplifies callbacks, and enhances usability with custom types, showing promise for functional programming.
OOP is not that bad, actually
The article compares Object-Oriented Programming (OOP) and Haskell's functional programming, highlighting OOP's advantages in collaboration, library extension, and backward compatibility, while noting Haskell's challenges in these areas.
- Prolog is frequently mentioned as a mind-blowing language, praised for its unique approach to problem-solving.
- Many users highlight the transformative experiences they had with languages like Haskell, Rust, and Erlang, emphasizing their innovative features and paradigms.
- Several commenters express admiration for languages that simplify complex tasks, such as Go and Python, which promote clean and efficient coding practices.
- There is a notable appreciation for languages that introduce unique concepts, such as APL's concise syntax and Lua's metatables.
- Users share nostalgic reflections on their early programming experiences, often linking them to foundational languages like BASIC and Pascal.
Just some additional commentary too - I think this post quite misrepresents it with some of the comparisons.
Prolog at its core is SLD Resolution [1] (a form of search) over Horn Clauses [2] (first order logic). Queries posted to the runtime are attempts to find a set of values which will satisfy (cause to be true) the query – whilst SQL is founded on relational algebra which more closely aligned with set theory.
Whilst there's probably some isomorphism between satisfying/refuting a logical predicate, and performing various set operations, I'd say it's a bit of a confusion of ideas to say that SQL is based on 'a subset of Prolog'. The author might be thinking about Datalog [3], which is indeed a syntactic subset of Prolog.
[1]: https://en.wikipedia.org/wiki/SLD_resolution [2]: https://en.wikipedia.org/wiki/Horn_clause [3]: https://en.wikipedia.org/wiki/Datalog
- tables (hashmap)
- regex
- pass by reference (caused a lot of confusion and frustrating bugs)
- metatables
- goto and labels
- multiple return values
After Lua I did want to try a language that's fast, something compiled to small native binary. My choice was Nim. And Nim got my mind blown to pieces: - static types
- function declarations I can understand how to use without reading their code
- functional paradigm
- batteries included standard library
- compile-time functions
- generics
- templates
- macros
- exploring and manipulating AST
- const, let, var (immutability)
- pointers and references
- compiler optimizations
- move semantics
- memory management
- I can compile code to both javascript and C?!
- C, C++ and JS interop (ffi)
- I can read and understand source code of standard library procedures?!
- huh, my computer is fast, like crazy fast!!
- and probably more, but that's what I can recall now..
Having done all the functional, lisp-like, logic, stack-based, etc., "non-mainstream" languages, the one that most blew my mind so far is Verilog. Everything executing all the time, all at once, is just such a completely different way of thinking about things. Even though the syntax is C-like, the way you have to think about it is completely different from C. Like it looks imperative, but it's actually 100% declarative: you're describing a circuit.
Everything else maps pretty close to minor extensions over OOP after you've worked with it for a while. Except logic languages, which map like minor extensions over SQL. Verilog to me was in a class of its own.
Then Rust took it a few levels beyond Go.
It’s a really good list, I suspect the languages you add is going to spend on your experience. So I wouldn’t feel too sad if your favorite language is on that list. The author lists Java as a language with an amazing standard library, but something tells me a lot of people will have C#, Go or similar as their Java, and that’s fine!
1. Basic on ZX Spectrum around 5-6 years old. Draw circle and a box and a triangle and... Look ma, a rocket!
2. Pascal around 10-12. I can write a loop! and a function. But anything longer than 100 lines doesn't work for some reason. C is also cool but what are pointers?
3. PHP around 14-15. The Internet is easy!
4. Perl around the same time. I can add 5 to "six" and get "5six". Crazy stuff.
5. C around 16-17. Real stuff for real programmers. Still didn't understand pointers. Why can't it be more like Pascal?!
6. C++ around 18-19. I can do ANYTHING. Especially UIs in Qt. UI is easy! Now, let's make a Wolf3d clone...
7. Common Lisp + Emacs Lisp around 20. No compilation?! REPLs? What are atoms? Cons cells? Live redefinition of everything? A macro? A program image?
8. Python around 22. Ok, so languages can be readable.
9, 10, 11, ... StandardML for beautiful types and compiler writing, vanilla C and x86 assembly/architecture the deep way, back to Lisps for quick personal development...
Looking back, it's Lisps and vanilla C that sticked.
Later: Lisp again, because of closures and CLOS let you program how method dispatch should work and CLCS let you resume from just before an error. Haskell, because you can lazily consume an infinite structure, and every type contains _|_ because you can't be sure that every function will always return a value. Java, back when the language was poor but the promise was "don't send a query, send code that the backend will run securely" (this was abandoned).
X |> one |> two |> three
versus the more conventional
three(two(one(X)))
Squares = [X*X || X <- [1,2,3,4]].
(This can be read as, Squares equals a list of X*Xs such that each X is a member of [1,2,3,4])Going from that to then realizing that you can use list comprehensions to implement quicksort in basically 2 lines of code:
qsort([]) ->
[];
qsort([H | T]) ->
qsort([ X || X <- T, X < H ]) ++ [H] ++ qsort([ X || X <- T, X >= H ]).
These examples are written in Erlang though list comprehensions are found in many other languages, Python and Haskell to name a couple.Then had to do things in OS/2, and then it was the REXX turn. Shell scripting didn't had to be as basic as I knew from DOS. Some years later moved to bash, and from complex script to long but very powerful oneliners, so it was another shock.
Still was working with OS/2 when learned Perl, and regexes, and its hashes, and all with some interesting semantic approach on that. And for many years it was my "complex" shell scripting language. Python was not as mindblowing or at least had the same kind of impact on me.
Prepare to have your mind blown: https://ratfactor.com/forth/the_programming_language_that_wr...
Imagine going from pre World Wide Web - and for many companies pre-email - age of local area networks (for file sharing only) and 38.K modems directly to group and user oriented, email integrated, distributed, replicated, graphics and multimedia integrated, no-code, document oriented, user programmable, fully GUI, secure, distributed database applications.
Lotus Notes blew my mind completely. A truly amazing application at the time.
- MacBASIC: Mac GUI programming w/o Pascal or C https://www.folklore.org/MacBasic.html (which is something I'll never forgive Bill Gates for)
- HyperCARD (also on that list, and agree with almost all points made): It was magic to get into Developer mode and to create stacks --- it's unfortunate that Asymetrix Toolbook didn't get further, nor that the Heizer stack for converting HyperCard stacks to Toolbook wasn't more widely available, and a shame that Runtime Revolution which became Livecode reneged on their opensource effort --- hopefully someone will make good on that: https://openxtalk.org/
Unfortunately, I never got anywhere w/ Interfacebuilder.app or Objective-C....
- Lua: real variables in TeX! (and latex), and one gets METAPOST as well --- even recursion becomes simple: https://tex.stackexchange.com/questions/723897/breaking-out-...
- OpenSCAD: Make 3D things w/o having to use a full-fledged CAD program
- BlockSCAD: Make 3D things w/o typing: https://www.blockscad3d.com/editor/ (though to be fair, https://github.com/derkork/openscad-graph-editor also allows that)
- PythonSCAD: variables and file I/O for OpenSCAD (though to be fair, RapCAD had the latter, it was just hard to use it w/o traditional variables) https://pythonscad.org/
Still working through a re-write of my OpenSCAD library in Python: https://github.com/WillAdams/gcodepreview and am hopeful that a tool like to https://nodezator.com/ will make that graphically accessible (w/o going into OpenSCAD mode to use OSGE).
GraFORTH (build the program up rather than down, mindbogglingly fast 3D graphics on the II)
TransFORTH (same thing, with floats)
Pascal and C (build up or down, convenient syntax)
APL (because it's extremely concise, and taught me the value of understandable code - focus on why, the program already says what and how)
Actor (like Smalltalk, but with a less surprising syntax)
Smalltalk (because the syntax IS important)
Visual Basic (because an integrated interface designer is immensely helpful)
Python (because batteries included)
Haskell (everything is clear once you rotate the program 90 degrees on the time axis)
Rust (because the compiler saves me from myself)
Common Lisp, which at the moment is the only language I can see myself using unless I decide to make one myself, never really blew my mind, although the little things it does make it hard for me to imagine switching away from it.
And there is this XL language that has very interesting approach to extending the language, but sadly the compiler is not in a runnable state, I could only assess it by the docs.
In recent years, Go blew my mind with it's simplicity and how strong of a case it makes for writing boring code.
It's been decades since writing C/ASM and my guess is what little I remember isn't applicable anymore, but I plan on diving in again at some point if only to better understand Go.
TS + PixiJS is a reasonable replacement for some of it now, but I still sometimes miss having compile-time warnings.
I happen to be learning functional programming and really struggling with a different way of thinking, at the same time I saw the movie Arrival, with the alien language as main plot point.
It struck me that what programming language we pick, fall in love with, dig into, does seem to change our thinking and ways of approaching problems. It can actually change our brain.
And then Awk, and associative arrays. You can literally create any data structure you need using associative arrays. It won't be fast; but if I could have only one container type, this would be it.
And then TCL, which is where I really learned to appreciate meta-programming. (I wrote Tcl's "Snit" object system in pure Tcl; it got quite a lot of use once upon a time.)
I make it a point to check out new languages on a regular basis, just to keep myself fresh (most recently, Rust and Haskell).
Strand is a logic programming language for parallel computing, derived from Parlog[2] which itself is a dialect of Prolog[3]. While the language superficially resembles Prolog, depth-first search and backtracking are not provided. Instead execution of a goal spawns a number of processes that execute concurrently.
http://www.call-with-current-continuation.org/strand/strand....
Mainstream CPUs expose one or more explicit stack pointers, and in assembly you use that all the time, right?
* C++: The feeling that I can make a-n-y-t-h-i-n-g. (not true but still mostly true) * Ruby: elegant, OO, who-needs-compile-time-if-you-have-unit-tests * Haskell: hard to learn but so worth it, by doing so I became a follow-the-types person * Elm: not hard at all, a well picked subset of Haskell for browser apps only * Kotlin: a well typed Ruby, with the ecosystem of the JVM at your disposal * Rust: when every bit of runtime performance counts (but now without sacrificing safety like with C/C++)
Here are three DSLs that left lasting and positive impressions:
1) Mathematical programming languages, first GNU MathProg, then later python pulp and pyomo. These launched a subcareer in applying LP and MIP to practical, large-scale problems. The whole field is fascinating, fun, and often highly profitable because the economic gains from optimization can be huge. Think of UPS.
2) Probabilistic programming languages, first BUGS (winbugs, openbugs, JAGS), later Stan, pymc, and various specialized tools. These helped me become a practicing Bayesian who doesn't much like p-value hypothesis testing.
3) The dplyr | ggplot universe. These are really two independent eDSLs but they're from the same folks and work great together. Writing awkward pandas|matplotlib code is just soul-wrecking tedium after using dplyr|ggplot.
BASIC, but specifically on a TRS-80. I can just type something in and run it. I don't have to wait a week for the teacher to take the card deck over to wherever the mainframe is.
Pascal. That's it, all of it, in those ~4 pages of railroad diagrams expressing the BNF.
C. Like Pascal, but terser and with the training wheels removed. It just fits the way my mind works.
Java. The language itself is kind of "meh", but it has a library for everything.
Perl. Regular expressions and default variables.
Not entirely https://eyg.run/
Turbo Pascal. Woah this is fast. And Mum is impressed when code sells for money.
Visual Basic. I'm living in the future, Ma. Dentist has a side business sell flowers and needs a program that can handle root canal and roses? I got you.
Perl. Suddenly system administration is fun again.
Java. My mind is blown, in a bad way. This is what I have to write to keep a roof over my head? Ugh.
Go. Aaahhh. Feels like reading W. Richard Stevens again. Coming home to unix, but with the bad parts acknowledged instead of denied.
And I'd also like to know how different Coq and Lean are. I'm not a mathematician. I'm just a software developer. Is there a good reason for me to pick one over the other?
In old versions the JVM does jsr and ret. In new versions it just duplicates the code. I don't understand what's mind blowing about it?
- Python: slicing, full reflection capabilities, and its use as an interface to almost anything [1], not to mention its role as an embedded interpreter (beyond the GIL debate).
- Z3: one of the closest I know for defining the ‘what’ rather than the ‘how.’ I got lost with Prolog when I tried to add more complex logic with ‘hows’, though I was a complete newbie with Prolog. Z3, however, really boosted my beginner capabilities.
- OMeta: allows me to write fast parsers without spending time resolving ambiguities, unlike ANTLR and other popular parsers using classical techniques.
- Smalltalk/Squeak: everything can be re-crafted in real-time, a blend of an OS and a programming language. The community vibe is unique, and I even have friends who implemented an operating system using Squeak. The best example? TCP/IP implemented in Smalltalk/Squeak! [3]. David Weil and I also created an early proof of concept [4] that used Linux behind the scenes, aiming to ‘compete’ with the QNX floppy disk.
- AutoLISP: a programming language embedded in AutoCAD, which I discovered in high school in the late ’80s—only to just find out that its first stable release is considered to be around 1995 [5].
- REXX on the Commodore Amiga: not only could applications be extended with this language, but they could also interact with each other. A decade later, when I used REXX on an IBM Mainframe, I still preferred the Amiga’s approach.
- Racket: I can draw in the REPL. For example with Racket Turtle.
- C++: object orientation "for C". I was not mesmerized by templates.
- Clipper: first database usage and relatively simple to create business apps.
- Objective-C: the first implementation of GCD [1], providing a C/C++ style language with fast performance, a clean event-loop solution, and reflective capabilities. However, I never liked the memory handling.
- Machine Code/Assembler on the Apple IIe: I could jump directly into the assembler monitor from BASIC.
- APL: a powerful yet complex way to program using concise expressions. Not ideal for casual use—best suited if you really understand the underlying concepts.
By the way, it’s time for Apple to embrace programming languages on iOS and iPadOS!
[1] http://www.garret.ru/dybase.html
[2] https://wiki.squeak.org/squeak/1762
[3] http://swain.webframe.org/squeak/floppy/
[4] http://toastytech.com/guis/qnxdemo.html
C++: pointers, OOP and so much more - good and bad - all in one package
Fortran90: vector programming for humans
Python: general programming for humans
Biggest disappointment: Scratch. Why isn't visual programming more mind blowing?
Anyway, always looking out for these well-regarded "mind-blowing" languages but somehow they never show up in really mind-blowing projects? Would be interesting in this respect to have a list of mind blowing projects that were only possible due to a mind-blowing language.
No mention of Reflection? Try-catch/Exceptions?
Are there large models that fully learn all programming language design principles and all user codes?
Truly achieving natural language programming.
Why?
Practical Phase:
$Basic - look, I can print things to the screen $Assembly - I have no clue what's going on $Matlab - Ok, this mostly makes sense and I can chart graphs and make functions $Python - ok I can do all kinds of automation now. It would be great to create an executable to give someone, but this apparently requires traversing the inner circles of hell. $SQL - declarative languages are weird, but it's easy to get up to speed. I'm doing analysis now over multi-TB datasets. $GAMS - a declarative language for building linear programming and other kinds of mathematical optimization models (algebraic modeling). This language is weird. Ok. Very weird. I'll go back to the Python API. $Unix/Bash/Awk - ok, I'm doing everything through the command line and it is beautiful, but after a short while I have to switch to Python. $Powershell - kind of like the Linux command line, but way more powerful and a lot slower. Can write more complex code, but often the cmdlets are too slow for practical use. Have to move back to Python a lot.
Exploration:
$Lisp - this is supposedly the best language. Read several books on language. Everything seems less readable and more complicated than Python. Aesthetics are fine. A lot of power here. Limited libraries. $Haskell - this seems like it is trying too hard. Too much type theory. $APL - this is really cool. Typing with symbols. Scalars, vectors, and matrices...yeah! $Prolog - very cool, but ultimately not that useful. We have SQL for databases and other ways to filter data. Prob a good niche tool. $Forth - this is amazing, but I'm not a low level hardware coder, so it has limited value. Hardly any libraries for what I want. $Smalltalk - the environment and GUI is part of the application...what? $Rebol - way too far ahead of its time. Like lisp, but more easy to use and dozens of apps in a few lines of code. Amazing alien technology. $Java - OMG...why does everything require so much code? People actually use this ever day? Aghhh. $C - where is my dictionary/hash type? What is a pointer? A full page of code to do something i can do in 3 loc of Python. At least it's fast. $Perl5 - cool. It's like Python, but more weirdness and less numerical libraries and a shrinking community. $Perl6(raku) - They fixed the Perl5 warts and made a super cool and powerful language. Optimization seems like it will take forever though to get it performant. $OCaml - pretty and elegant. They use this at Jane Street. Why is it so hard to figure out how to loop through a text file (this was 10 years ago)? $8th - a forth for the desktop. Commercial, but cheap. Very cool ecosystem. Small and eccentric community. I wish this would be open sourced at some point. $Mathematica - by far the most powerful programming tool/environment I've used for practical engineering and science work. Like lisp, but no environment/library problems. Commercial and pricey. I can create a directed graph and put it on a map of my home town, train a neural network, do differential equations, and create a video out of my graphs all in a single notebook with built-in functions. Nice! $Swift - can I not get this on Windows? $F# - oh it's OCaml on .Net, but the documentation is a little hard to follow. Everyone assumes I know C# and .Net. $Clojure - Rich Hickey is a genius. A lisp IT won't fire me for installing. Oh wait...I don't know the JVM. Workflow kind of soft requires emacs.
Related
I Probably Hate Writing Code in Your Favorite Language
The author critiques popular programming languages like Python and Java, favoring Elixir and Haskell for immutability and functional programming benefits. They emphasize personal language preferences for hobby projects, not sparking conflict.
You should make a new programming language
Creating a programming language enhances understanding of design and execution, fosters creativity, and provides valuable insights. Implementing existing languages and choosing different implementation languages can deepen learning experiences.
You should make a new programming language
Creating a programming language enhances understanding of design and execution, encourages learning through initial flaws, and fosters creativity. Guided projects and resources support beginners in this fulfilling endeavor.
Gleam Is Pragmatic
Drew Olson discusses the Gleam programming language, which merges Haskell and OCaml features, supports immutable data, simplifies callbacks, and enhances usability with custom types, showing promise for functional programming.
OOP is not that bad, actually
The article compares Object-Oriented Programming (OOP) and Haskell's functional programming, highlighting OOP's advantages in collaboration, library extension, and backward compatibility, while noting Haskell's challenges in these areas.