Hacker News new | ask | show | jobs
by luffy 5709 days ago
Looks like C# is borrowing even more from the F# playbook. Though from the looks of it, I still like the F# implementation better.

Next in C#: workflows ( aka F# monads ).

I really wish they had dabbled more in dynamic programmic. I'd have loved to see something akin to Python's multiple inheritance. ( EDIT: is this technically dynamic? :p )

3 comments

Anders Hejlsberg gives an introduction in this video where he mentions F# as a reference for ideas at the very beginning: http://channel9.msdn.com/Blogs/Charles/Anders-Hejlsberg-Intr...
"Dynamic programmic" would be a sweet name for a band.
Technically, no, dynamic programming just means solving smaller problems as part of a larger problem.

eg. dykstras algorithm for a shortest path, or a merge sort.

I think you're thinking of dynamic typing, which .NET and F# have, kinda, (via dynamic method invocation). In F# to invoke a method dynamically use the ? operator.

  x.Bar() # static call
  x?Bar() # dynamic call
in C# to do a dynamic call cast the object to Dynamic.

  ((Dynamic)x).Bar(); // dynamic call
  ((IFoo)x).Bar(); // static call
Also, you can do multiple inheritance in a static language, C++ as an example.