title: Use of if-else in JavaScript ES6
body: <p>I am learning ES6 and following is my ES5 code which is running fine -</p>
  
  <pre><code>var myArr = [34,45,67,34,2,67,1,5,90];
  var evenArr = [];
  var oddArr = [];
  
  myArr.map(function(x){
    if(x%2==0) evenArr.push(x);
    else oddArr.push(x);
  });
  </code></pre>
  
  <p>Now if I am converting this to ES6 I am getting errors of <code>Unexpected token</code> near <code>if</code>, let me know what I am doing wrong here - </p>
  
  <p>My <strong>ES6</strong> code -</p>
  
  <pre><code>var myArr = [34,45,67,34,2,67,1,5,90];
  var evenArr = [];
  var oddArr = [];
  myArr.map( x =&gt; if(x%2==0) evenArr.push(x) else oddArr.push(x) )
  </code></pre>