title: how to create an array of objects based on another array of objects?
body: <p>I have this array: </p>
  
  <pre><code>var arr1 = [
   {"user":"dan","liked":"yes","age":"22"},
   {"user":"sarah","liked":"no","age":"21"},
   {"user":"john","liked":"yes","age":"23"},
  ];
  </code></pre>
  
  <p>I'd like to create a new (sub)array of that array, containing only the likes of the users.</p>
  
  <p>so it would look like this:</p>
  
  <pre><code>var arr2 = [
   {"dan":"yes"},
   {"sarah":"no"},
   {"john":"yes"},
  ];
  </code></pre>
  
  <p>I tried:</p>
  
  <pre><code>var arr2 =[];
  for(var i in arr1){
    arr2.push({[i[user]]:i[liked]});
  }
  </code></pre>
  
  <p>it needs a tweak, 
  ideas?</p>