title: Is there an equivalent to Haskell's init function in elixir?
body: <p>In Haskell the <code>init</code> function returns all the elements in a list except the last element.<br/>
  For example <code>init [1, 2, 3]</code> would return <code>[1, 2]</code>.</p>
  
  <p><strong>Is there a similar function in Elixir?</strong></p>
  
  <p>I can't find any similar function in the <code>Enum</code> or <code>List</code> module.</p>