You can parse out a string to split or extract the information as follows:

<script type=”text/javascript”>
  var strProvinces = 'BC,AB,SK,MB,ON,QC,NL,NB,NS,PE,YK,NW,NV';
  var aProvinces = strProvinces .split(‘,’);
  alert(aProvinces[0]); // BC
  alert(aProvince[1]); // AB
</script>