title: turn array hex colors into array rgb colors
body: <p>I have an array of hex colors like this:</p>
  
  <pre><code>var hexColors = [
      "#ffffff",
      "#ffffff",
      "#ffffff",
      "#f3f3f3",
      "#f3f3f3",
      "#f3f3f3"];
  </code></pre>
  
  <p>I want to turn it into this:</p>
  
  <pre><code>var rgbColors = new Array(
  [62,35,255],
  [60,255,60],
  [255,35,98],
  [45,175,230],
  [255,0,255],
  [255,128,0]);
  </code></pre>
  
  <p>using this function :</p>
  
  <pre><code> function hexToRgb(hex) {
   var shorthandRegex = /^#?([a-f\d])([a-f\d])([a-f\d])$/i;
   hex = hex.replace(shorthandRegex, function(m, r, g, b) {
      return r + r + g + g + b + b;
   });
   var result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex);
   return result ? {
      r: parseInt(result[1], 16),
      g: parseInt(result[2], 16),
      b: parseInt(result[3], 16)
   } : null;
  }
  </code></pre>
  
  <p>How can I do? Thanks!</p>