3 ms·
I’ve used F# and USING it feels very similar to OCaml in all of the important ways. The lightweight type structure where you can easily make Union types and th
by Jorge1o1 7y ago
I’ve used F# and USING it feels very similar to OCaml in all of the important ways.
The lightweight type structure where you can easily make Union types and the pattern matching are pretty much identical to how OCaml does it.
Of course, the big difference is going to be in how easily you can interop with the .Net stuff in each language, obviously much easier in F#. This is great if you happen to have some kind of weird C# code that generates an IEnumerable, just pop that into F# and start working with it.
For example, I have C# classes to read files to an IEnumerable of strings, you can just call List.ofSeq on it, and then start doing some really elegant things in F# with it. You can pattern match log files based on how the line starts and then run different functions whether it’s an error, info, debug, etc