For the sake of this question, this is a simplified version of the problem I am having.

If I have a `<select>` in my HTML:

```
<select>
  <option value="1">1</option>
  <option value="2">2</option>
  <option value="3">3</option>
  <option value="4">4</option>
  <option value="5">5</option>
  <option value="6">6</option>
</select>

```

Then my JS:

```
var a,b = 12;
var c1,d1,e1,
    c2,d2,e2,
    c3,d3,e3,
    c4,d4,e4,
    c5,d5,e5,
    c6,d6,e6 = // Assigned individually from loop. NOT actual code.

function myFunction(a,b,c,d,e){
  // do something with a,b,c,d,e
}

$('select').on('change', function() {
  var id = $(this).val();
  c = c+id;
  d = d+id; 
  e = e+id;
  myFunction(a, b, c, d, e);
}

```

In the above code, if I select option 3, I want to pass the function variables c3, d3, e3.

How do I assign the '3' from the id to the variables passed? What is wrong with the select portion this code? 

Please help. Thanks.

---

**QUESTION #2: Following on from @David's answer** 

If I build an array of objects in the manner you suggest.

```
destinations = [
  {id:'123', title:'London',    lat:'1.52121' , lng:'-1.3423423', content:'a string'},
  {id:'456', title:'Paris',     lat:'1.52121' , lng:'-1.3423423', content:'a string'},
  {id:'634', title:'Amsterdam', lat:'1.52121' , lng:'-1.3423423', content:'a string'}
]

```

If I wanted then iterate through the array and create variables for GoogleMaps markers with each object, how do I 

```
$.each(destinations, function(i, ob) {
  $.each(ob, function (key, value) {
    var marker[ob.id] = new google.maps.Marker({
      draggable: false,
      map: map,
      icon: dotMarker,
      position: {lat: ob.lat, lng: ob.lng}
  }); 
});

```