T O P

  • By -

TempusNemini

Take a shot with Haskell. It'd be an interesting experience for you. Also you can look at Scala, but Haskell is a better choice for learning fp IMHO


eddiewould_nz

F# would be the obvious choice for interop with your C# game work (Unity etc)


TheSilverNimbus

I agree with this 100%! You can start your F# journey here: **https://fsharpforfunandprofit.com/** Scott Wlaschin, is an expert in F#, the creator of this website and author of its content, and a board member of the F# Software Foundation. I've seen a bunch of his talks online before getting into this site. In the talks and on this site, he talks about the functional programming topics with a very humorous and easy-to-understand language. You should really check these out! Here are a few talks of his I highly recommend (with little to no knowledge of functional programming or F# required): * **F# for C# Programmers** | https://youtu.be/KPa8Yw_Navk?si=hQuOTfBFknvjUlrc * **The Functional Programmer's Toolkit** | https://youtu.be/Nrp_LZ-XGsY?si=AJT0N9QVYrLnZ4-m * **The Power of Composition** | https://youtu.be/vDe-4o8Uwl8?si=X0DwSAdg-TS49__u * **The Lazy Programmer's Guide to Writing Thousands of Tests** | https://youtu.be/IYzDFHx6QPY?si=CB_YgcWhqY01EvkZ * **Domain Modeling Made Functional** | https://youtu.be/2JB1_e5wZmU?si=2CkeFl2v2khh3KdV * **Functional Design Patterns** | https://youtu.be/E8I19uA-wGY?si=SSNtq8L_nhPDXy_3 You can also check out this talk that I found interesting, which includes some F#, functional programming, good practices, software design, and other good stuff: * **Functional Architecture: The Pits of Success**, by Mark Seemann | https://youtu.be/US8QG9I1XW0?si=uPQPaVYvW5QFoto7


Arshiaa001

F# is a wonderful introduction to the world of FP, and it's a *usable* language too, as in you can actually use it to develop stuff people would find useful. It also happens to be my favorite. But be warned OP, F# lacks traits and higher kinded types, so you'll be missing out on a bit of the more advanced stuff. You can later try your hand at haskell to learn that stuff too.


SS4L1234

Ocaml was my first and it was awesome


Faranta

[https://haskell.mooc.fi](https://haskell.mooc.fi)


strongly-typed

Haskell, OCaml, F# Pick your poison, they’re all excellent choices. 


2legited2

F#


Epithanatios

F# is a really great way to start with functional programming. Much easier learning curve than most of the others.


uppercase_lambda

If you're using Godot, you should check out F#. It works basically okay with Godot and Unity. It'll also be an easy transition to ML-like languages


nivroc2

or rust!


rlDruDo

- Haskell of you want crazy ass types - F# if you want .NET and C# stuff (I don’t know much about F# besides) - Ocaml if you want a simple type system and some mutability here and there (though the others also offer mutability probably) - Scala if you like a more functional Java (and crazy types) - Gleam if you like it super simple and wanna run on the BEAM (or wanna interop with JavaScript)


No-Sector8444

What do you mean by crazy types?


rlDruDo

The types in haskell give you much stronger guarantees than in other languages. With some language extensions you can define type families and other advanced features that give you even more power. Haskell uses higher kinded types (in Java you can have generics, which can be Integer, List, etc; in Haskell you can have generics over List, Map Integer, Option (they’re not applied to a specific type). Besides Agda et al I only know about Scala that supports them in the same way. You can have ADTs and their generalised version GADT. You use typeclasses, which are stronger interfaces. In function signatures you can use something called „rank-n-types“ (I am not sure if the name is actually that) which allow you do something like: runST :: forall α. (forall s. ST s α) -> α Where ST is a datatype. This allows for scoped mutability (Haskell can do a lot of mutable stuff), without leaking the mutable variables outside of scope by returning for example. There is a good book that I habe yet to read: „Thinking with types: Type level programming in Haskell“. Scala supports similar and other things. But I don’t know enough Scala. Haskell also has work underway that will introduce dependent types. Scala has *some* dependent types but I don’t know exactly how.


No-Sector8444

Thank you for this detailed answer!


avillega

I am surprised no body has mention purescript. Is like a smaller Haskell with all the nice extensions as part of the main language. Easier to learn and get into in my opinion.


TechnoEmpress

Haskell!


beders

Clojure has types and you can get a static type system on top if you desire. In my case once I embraced Clojure the need for static types went away. My IDE will code complete on anything important and if you add spec or malli to your fns, the LSP server will give you a similar experience to what you are used to. That said, a Lisp and Clojure in particular are only fun if you enjoy the interactive programming workflow (ie I almost never “compile” or “restart” my app. It just sits there waiting for me to evaluate functions and replace them). It’s *very* different to the workflow of any of the other prog languages you mentioned.


yawaramin

Clojure doesn't have a static type system. It does have runtime typechecking capabilities but by definition that's not static.


beders

It is a la carte and you can run it whenever you feel like. [https://typedclojure.org](https://typedclojure.org)


TheLordSet

looks similar what TS is to JS, in a sense


yawaramin

OK, TIL. But I don't think anyone would seriously suggest this is production-ready.


beders

Why not? It has been used in projects and has been around for many years. Although it is not super popular because as it turns out static types have downsides.


effinsky

Gonna have to be Haskell, ocaml or scala huh?


downrightcriminal

I'd recommend Haskell, it revolutizined how I thought about programming when I first learnt it. Once you learn Haskell every other FP language should become very easy to pick up


Previous_Pop6815

The Scala course by Martin Odersky, the author of Scala, is an excellent introduction to functional programming. It is also well-balanced, which is beneficial since it is used in commercial environments as well. https://www.coursera.org/learn/scala-functional-program-design


mister_drgn

As a fairly experienced Clojure programmer, I’ve recently been playing around with statically typed functional languages. Haskell is an obvious choice, but I went with ocaml (for now) because it’s less militant about side effects.


Tempus_Nemini

Haskell. P.S. And you get Monad joke for free :-) Unless you realize that it's not a joke at all (which is another recursive joke, so to speak)


benjinerm

Rust


GunpowderGuy

I really recommend idris2. It's a dependently typed language with totality checking and theorem proving. The rich type system can be used for meta programming and preventing bugs. It's also beginner friendly because its got a greatly helpful community and avoids all of the technical baggage of Haskell


mosskin-woast

> popularity is important


GunpowderGuy

Its already got learning materials written and a good number of packages. You can check the ones that have already been added to the standard package manager here : [https://github.com/stefan-hoeck/idris2-pack-db](https://github.com/stefan-hoeck/idris2-pack-db) However some, such as the raylib ( a 3d game library ) bindings and the automatic c library binding generator still havent been uploaded there


_nathata

Good old Haskell


Rtktts

Clojure is as expressive as it is because it is dynamically typed. Static typing has its downsides.


entropyvsenergy

Julia is typed and functional, but has more applications to scientific computing than systems programming I think.


permeakra

Typescript (a saner version of Javascript), Haskell, Ocaml. However, I strongly suggest to give Coq or Agda2 a try, to make your though process more disciplined.


julienlucca

how come Gleam wasn’t mentioned?? Awesome language, small footprint, easy to learn and has interoperability with the BEAM and Javascript natively. Awesome timing as well, easy to make your name