F# or C# ?
Rsadeika
Posts: 3,837
I just heard about F#, what the heck is it? I was told it is the MS version of FORTH, and is a .net language. Anybody use it, and would it help in understanding how to use the Propeller version? Did we ever have a thread about the FORTH language? I mean in depth discussion about it.
Thanks
Ray
Thanks
Ray
Comments
That would be B and E.
F# is designed for mathematics.
Microsoft actually uses F# in a lot of back end systems where there is a need for strong functional work, for example, the ad system in Bing is written in F#. There is even a version of Go written in F# for the XBox 360 that shows the power of it.
Bill
Maybe this is better stated as... the F# language is based on ML/OCaml, and has been adapted to the .Net framework.
Basically, it's OCaml .Net.
Units of measure - that allow you to type-check code dealing with numerical calculations
Meta-programming using quotations - (which makes it possible to use LINQ in F# and is also essential for promissing projects like the WebSharper platform)
Active patterns - for creating abstractions for functional data types (and generally very useful feature for more complicated pattern matching applications)
Computation expressions - which is a langauge feature behing asynchronous workflows (a library for asynchronous I/O/web service/GUI programming)
.NET compatible object-system - that makes it possible to fully interoperate with the .NET platform (OCaml also has a support for objects but different - there are of course some benefits in both of the systems).
Overloaded operators - OCaml doesn't have overloaded operators - as an example, in F# you can use + for all numeric types as well as your types that support it.
I think that if you stuck to very basic OCaml code, you could get it to compile in F#, but the real power is in it's ability to do the advanced math and multiprocessor i/o, which isn't a feature of OCaml. (In fact, there really is no benefit to using it other than these features in my opinion.)
Bill
peter ..