title: How are types in FP fundamentally different than an object in OOP?
body: <p>Forgive my noobness as I'm new to FP. Been working with Elixir, so I tagged it.</p>
  
  <p>When I use Elixir's iex, I can inspect a variable's type using <code>i</code>. e.g. <code>i "hello"</code> shows me I can use <code>String</code> module's functions on it. I can do <code>String.downcase "HELLO"</code> which seems exactly like sending a message to an object that returns another object, but expressed in a different way to appear like a mathematical function. The <code>i</code> helper also seems like checking the class of an object which then helps me figure out all the methods available in that object.</p>
  
  <p>I understand immutability is a key feature in functional programming. I can do immutability easily with many OO languages too, but the onus is on the programmer.</p>
  
  <p>I've been reading Elixir books and blogs that recommend I forget my OO mindset and think fundamentally differently. I just don't get how they're fundamentally different and require a change in mindset when the only difference is immutability.</p>