Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>You don't necessarily have to choose between the two paradigms. You can write software with an OO architecture using many functional concepts. <strong>FP and OOP are orthogonal in nature</strong>.</p> <p>Take for example C#. You could say it's mostly OOP, but there are many FP concepts and constructs. If you consider <strong>Linq</strong>, the most important constructs that permit Linq to exist are functional in nature: <strong>lambda expressions</strong>.</p> <p>Another example, F#. You could say it's mostly FP, but there are many OOP concepts and constructs available. You can define classes, abstract classes, interfaces, deal with inheritance. You can even use mutability when it makes your code clearer or when it dramatically increases performance.</p> <p>Many modern languages are multi-paradigm.</p> <h2>Recommended readings</h2> <p>As I'm in the same boat (OOP background, learning FP), I'd suggest you some readings I've really appreciated:</p> <ul> <li><p><strong><a href="http://msdn.microsoft.com/en-us/magazine/ee309512.aspx" rel="noreferrer">Functional Programming for Everyday .NET Development</a></strong>, by Jeremy Miller. A great article (although poorly formatted) showing many techniques and practical, real-world examples of FP on C#.</p></li> <li><p><strong><a href="http://www.manning.com/petricek/" rel="noreferrer">Real-World Functional Programming</a></strong>, by Tomas Petricek. A great book that deals mainly with FP concepts, trying to explain what they are, when they should be used. There are many examples in both F# and C#. Also, <a href="http://tomasp.net" rel="noreferrer">Petricek's blog</a> is a great source of information.</p></li> </ul>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload