F#: String.Join and |> operator

String.Join is a .NET method. When using a .NET method, F# views it as a function that takes a tuple as an argument (when calling it you write parameters as f(a, b)). The |> operator can be used with functions that use the curried form of parameters (and can be called by writing f a … Read more

When should I use let, member val and member this.?

The answer from @meziantou already gives a nice overview of the options (and how they behave differently), so let me just give a brief summary, or list of recommendations: Use let or let mutable if you want to define a local value that is visible only within the type (essentially a private field or a … Read more

Why does the power operator in F# only work for floating point numbers?

(**) and pown are two different things. When you see (**), you can think of the mathematical formula using logarithms. When you see pown, it’s just a series of multiplications. I understand it can be surprising/confusing at first, because most other languages don’t make such a difference (mainly because integers are often implicitly converted to … Read more

What are advantages and disadvantages of “point free” style in functional programming?

The point-free style is considered by some author as the ultimate functional programming style. To put things simply, a function of type t1 -> t2 describes a transformation from one element of type t1 into another element of type t2. The idea is that “pointful” functions (written using variables) emphasize elements (when you write \x … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)