Convert slice-based BAC code into array based