Sort a array to form three array : I want to sort an array in a way that it give back three arrays. So`

    ``` var myArray = ['1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3','1','2','3'];
```


here the values can be numbers, string, objects etc.

I want three arrays Like :

    ```
var myArray1 = ['1','1','1','1','1','1','1','1','1','1'];
var myArray2 = ['2','2','2','2','2','2','2','2','2','2'];
var myArray3 = ['3','3','3','3','3','3','3','3','3','3'];
```


I want to know the Logic.