This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Advice to code in FP style

 
Raymond Tong
Ranch Hand
Posts: 255
2
IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Scala is a hybrid language that could code in FP and OO style.
Any advice to help people from OO background to think and write in FP style in Scala?
Would you think it would be better to learn FP in pure FP language like Clojure, Haskell?

Thanks,
Raymond
 
Joe Harry
Ranch Hand
Posts: 10106
3
Eclipse IDE Mac PPC Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Raymond Tong wrote:Hi,

Scala is a hybrid language that could code in FP and OO style.
Any advice to help people from OO background to think and write in FP style in Scala?
Would you think it would be better to learn FP in pure FP language like Clojure, Haskell?

Thanks,
Raymond


From my personal experience, I found that a gradual migration from an imperative style to a functional style helps a lot. Scala is very much adept at it since it is both a FP as well as OOP as opposed to purely FP languages like Haskell and co.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic