• 3 Posts
  • 3 Comments
Joined 21 days ago
cake
Cake day: April 4th, 2025

help-circle



  • A few more thoughts here:

    • for a first Distribution, Ubuntu is fine, too. Also, you could ask people arounf you what they know best und whether they like to help you. For example, Debian is a bit harder to install but is rock solid once it runs.
    • if you are concerned about security, you should practice a strict separation between trusted software installed by you, and untrusted data presented to you via web, mail or Internet. Never run untrusted code. Windows blurs that line and this is fatal.
    • In respect to hardware support: Most standard PC hardware will work very well with Linux, even old scanners that have no more Windows driver support. NVidia is the bad exception, and the bad rap is still justified because of Wayland, the new graphics display server. If you are not really poor you might consider to buy something better. The hardware support landscape is different for laptops. Here, refurbished Lenovo Thinkpad or Dell laptops are first choice, and also best value for the money.

  • I want to learn / use a functional programming language.

    That’s a good idea.

    With over 20 years of programming in languages like C, C++, Python, Go, Pascal, Forth and so on, I think functional languages are often easier - in the same way that programming without lots of global variables is usually and objectively better. There are of course a few domains where the OOP approach works better, like defining data structures with tight invariants, Linux hardware drivers, or simulating ships.

    Or sometimes, you need a bit of imperative code for a number-crunching core.

    But most code can advantageously be represented and structured as:

    input -> transformation -> output

    and the transformation part, which is almost everything which is really interesting, is where the functional style shines.

    Now if you want something beginner-friendly and practical, it depends on what you want to do. Here my ten cents:

    For systems programming, signal processing and embedded stuff, I’d totally recommend Rust. It has certainly a bit of Algol syntax but that’s rhe proverbial wolf in sheeps clothing: Many concepts actually come from OCaml, as well as the first Rust compiler. This would also answer the question whether functional languages are relevant and useful in industry.

    If you want to do concurrent server-side programming, I believe there is nothing better than Clojure - perhaps with Babashka for scripting and ClojureScript for the Browser. Clojure is also incredibly elegant and concise, and at the same time it can use Java libraries, so it has huge library support, a battery powerhouse included.

    If you learn both, you will see that Clojure and Rust have actually a lot in common in their approach to concurrency, which is preventing shared mutable state. It is great to learn both.

    If you want a very practical, well-documented, and beginner-friendly language that also has great GUI support, I’d recommend Racket, a Scheme descendant. Like Clojure, it supports gradual typing.

    If you want to program close to the Unix/Linux environment and want a simple as well as powerful language, a Scheme version could be a good choice. Personally, I love Guile, and use it where I previously used Python. Guile is very easy to use as a extension library for C and C++ programs or to control low-level code written in C. It also has a quite good REPL and debugger support and thus, interactive experience.

    Speaking of Python, it has a great vector library which is heavily influenced by APL and functional designs, named Numpy. A C++ analogon would be Eigen. You see that functional programmers subversively introduce their filth everywhere!!

    For data analysis, Scala could be an option. It is like OCaml on the JVM. Similarly, F# for .NET (but who wants to get entangled in Windows?).

    If you want to keep it more multi-paradigm, you could chose Common Lisp - it will let you program in many styles and its SBCL implementation probably has the best performance after Rust. But Schemes like Guile or Racket are more geared toward a functional-preferring style. And if you want Lisp with stricter typing, there is Coalton - but I have not tried that last one.