Q:

combine and merge two array into set of arrays for Highchart Pie

I have set of two arrays like this:
["Arrear Bonus","HRA","Rent",....]    
[58880,25211,21355,12341,.....]

and in Highcharts Pie i need to show the series like this:
$(...).highcharts({
....
....
series: [
         ["Arrear Bonus",5880],
         ["HRA",25211],
         ["Rent",21355],
        ]
});

So basically i need to create a chunk of arrays by my two arrays set;
i tried this:
    var expense_name = amounts.expense_name;
        var expense_amount = amounts.expense_amt;
        var arr3 = {};

        $.each(expense_name, function(i, value){
          arr3[value] = expense_amount[i];
        });

but i got this:
{ Arrear Bonus: 12000,HRA: 121331,Rent: 17744...}

how can i achieve this result:
       [
         ["Arrear Bonus",5880],
         ["HRA",25211],
         ["Rent",21355],
        ]

A:

Set your arr3 var as an array and push elements into it :
var expense_name = amounts.expense_name;
var expense_amount = amounts.expense_amt;
var arr3 = [];

$.each(expense_name, function(i, value){
  arr3.push([value,expense_amount[i]]);
});

