結果 : loop through array and change value javascript