3 ms·
The design approaches for Scala and F# are different though: F# is mostly FP with some OO tackled on - mainly influenced by OCaml. Scala unifies both OO and FP.
by pkolaczk 13y ago
The design approaches for Scala and F# are different though: F# is mostly FP with some OO tackled on - mainly influenced by OCaml. Scala unifies both OO and FP.
> If you know f#, you practically know Scala - well, enough to be instantly productive.
Sure, but actually you can say the same about knowing Java/C# and then moving to Scala. But in that case you're missing a whole lot of features that Scala offers that F# does not: typeclasses, traits, implicits, etc.
- balakk 13y agoTrue. I was referring to similarities in things like higher-order functions, tail-recursion support, pattern matching, option types and so on. I feel the intersection of FP features between F# and Scala is much greater than C#/Java.
- CmonDev 13y ago"F# is mostly FP with some OO tackled on - mainly influenced by OCaml. Scala unifies both OO and FP" So Scala is mostly OO with some FP tackled on?
- tel 13y agoIn my understanding, it's hard to say. It appears to have a base semantics that you can think through as OO-like message passing or FP-like lambda calculus reduction. I assume it's implemented OO-style on the JVM, but it's hard to say whether the core language biases one side or the other. I think that's interesting but also a big indicator of why you see such a big split-brain situation in Scala. FPers program FP-Scala, OOers program OO-Scala, but neither is dominating. As far as I can tell, Martin Odersky programs balanced OO-FP, but few others do.
- andrewcooke 13y agoscala is the unholy child of everything from oo and everything from fp (well, almost). (but i found it hard enough to program in ocaml, which is similar to f#, because i was always torn between oo and fp parts, so maybe i am biased or just Too Dumb For Scala)