SHARE
TWEET

Untitled

a guest Mar 21st, 2012 15 Never
  1. var data = [];
  2. var i=0;
  3. for (i=0;i<50000;i++) {
  4.  data.push([Math.random(),Math.random()])
  5. }
  6. var swapedData = [];
  7.  
  8. console.log(+new Date())  //1332356389339
  9. for (i=0;i<data.length;i++){
  10.   swapedData[i] = [data[i][1], data[i][0],]
  11. }
  12. console.log(+new Date()) //1332356389548
RAW Paste Data
Top