New OCaml books?

I wonder, why there are no new OCaml books since 2014 year? Many books are published on Haskell, Scala, F# themes, but no OCaml. I think we need new books for learning and for rising interest in our beautiful language.

4 Likes
8 Likes

Beautiful!! Many Thanks for information!

A Chinese book OCaml语言编程基础教程 (an introduction to OCaml language programming) is published in 2018.

5 Likes

I’m working on a free culture book. The preview is at https://ocaml-book.baturin.org and the source is at https://github.com/dmbaturin/ocaml-book

It’s under CC-BY-SA so it belongs to the community—it can be a living document that people can keep up to date even if original authors abandon it. It’s also supposed to be a collaborative project, but almost no one is collaborating so far. :wink:

17 Likes

I’m also working on a free culture book. The preview is at https://damien-guichard.developpez.com/downloads/Algorithmic-with-OCaml.pdf

It’s under CC-BY-SA.

Planned chapters includes : Records, Type polymorphism, Modules as functions, Conceptual graphs.

The reason why i don’t contribute to @dmbaturin’s effort is that my main topic is algorithmic, ocaml is more a good way than a goal.

6 Likes

That link is asking me to authenticate.

No need to justify yourself. The more good books and views there are, the better.

2 Likes

Sorry, you have to be a member of https://www.developpez.com/ to access this link.

Here is my 2nd try. I hope you don’t need to be a member of https://www.aeriesguard.com/ this time.
https://www.aeriesguard.com/media/get/504bfbe34d3f517c8acf37ffbe200f84698aca0c/Algorithmic-with-_OCaml.pdf

6 Likes

what about a way to submit leetcode solutions in ocaml?

I’ve been wanting this and I have some ideas to pull some libraries together.

4 Likes

This works, thanks.
Where should I post suggestion/bugs to this?

I would say it’s just an early draft, more debate will come when i have more content to offer.

1 Like

Hello,

Just chiming into the conversation to ask what is the ideal book/tutorial to get into OCaml? I am a data scientist which means that I do code at work (we use scala, python and I have experience with C++) but of course I am not a software engineer. I have seen that book that might interest me [ANN] Draft of OCaml Scientific Computing book

Also, is the book by Mr Leroy and Weiss still useful today? (https://caml.inria.fr/pub/distrib/books/llc.pdf) (I mean, has the syntax/language not changed too dramatically? )

Maybe I could read that one (I can read french) and have another resource for more “modern” syntax (if it has evolved). Which one?

Thanks!

You might like this:
https://www.cs.cornell.edu/courses/cs3110/2019sp/textbook/

And of course Real World OCaml, mentioned in comments above.

Good luck!

3 Likes

There is also an updated version of the Cornell course material online. The new version has embedded video lectures in most (all?) chapters and you can submit changes via github.

OCaml Programming: Correct + Efficient + Beautiful

7 Likes

The language has not changed much. There are some extensions and new features, but programs from 15 years ago are usually still compiling.
I do not think there is a great book for tooling though, from what I remember, real world ocaml was not completely up to date on the subject, and le language caml will probably be even worse

Introduction to Objective Caml by Jason Hickey is my fav introductory book on OCaml!

I recently read the book Learn Rust in a Month of Lunches the MEAP version from Manning and it is excellent. The reason why I am writing this is because I really wish to see such a book but for OCaml. Such kind of books for OCaml are really missing unfortunately.

1 Like

Most of the language has not changed for 15 years, but the eco-system has evolved. Dune, Opam, PPX. However, the Real World OCaml 2nd edition (published in 2022) address these features and seems to be rather complete.

What should be needed ? I guess a book which address OCaml 5 evolutions (threads, Eio). Also, a book similar to The LaTeX Companion: it would propose a best-of of many available libraries with short example and makes it easier to choose among the large available choice.

The book “OCaml Scientific Computing Tutorials” fills also a nice niche, but I don’t know if there are many other domains which would justify a dedicated book. Perhaps the whole Ocsigen framework, but the online documentation seems to be adequate.

1 Like

A “Polyglot OCaml” book might be useful. Specifically addressing the various ways to integrate OCaml and a set of popular languages: Rust, Go, Javascript, Python, Java, in addition to the standard C/C++. It’d be nice to have a single source of info for such stuff.

1 Like

What aspects of that book have you liked that you don’t find in the other OCaml books available?