I have a mixed array that I need to sort by number, alphabet and then by digit-
[\'A1\', \'A10\', \'A11\', \'A12\', \'A3A\', \'A3B\', \'A3\', \'A4\', \'B10\', \'
var a=[ {
"LIST": "14:NATURAL RESOURCES"
},
{
"LIST": "7:DIVERSITY IN LIVING ORGANISMS"
},
{
"LIST": "3:ATOMS AND MOLECULES"
},
{
"LIST": "10:GRAVITATION"
},
{
"LIST": "6:TISSUES"
}]
var c=a.sort(function(a,b){
let aa=a.LIST,bb=b.LIST;
return parseInt(aa.split(":")[0] - bb.split(":")[0])
})
console.log(c)