Question: HTML CODE

```
<select class="form-control" name="min_select[]">
              <option value="15">15</option>
              <option value="30">30</option>
</select>

```

JQuery Code

```
var val1[];
$('select[name="min_select[]"] option:selected').each(function() {
val1.push($(this).val());
});

```

when i run this code I get empty val array

Answer: 
The declaration array syntax is in correct.Please check the below code 

```
 var val1=[]; 
 $('select[name="min_select[]"] option:selected').each(function() {
  val1.push($(this).val());
 });

```
To get the selected value, whether it is multiselect or single select, use jQuery [`.val()`](http://api.jquery.com/val/) method. 

If it is a multiselect, it will return an array of the selected values.

See [jsfiddle for demo](https://jsfiddle.net/txk25c4c/). Check console log