void PrintChromo(int bits[]) { printf("I AM PRINTCHROMO!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"); int buffer[(int)(BITLENGTH / GENELENGTH)]; int numberOfElements = ParseBits(bits, buffer); int p; for(p = 0; p < numberOfElements; p++) { PrintGeneSymbol(buffer[p]); } }
//---------------------------------PrintChromo--------------------------------------- // // decodes and prints a chromo to screen //----------------------------------------------------------------------------------- void PrintChromo(string bits){ //holds decimal values of gene sequence int buffer[(int)(CHROMO_LENGTH / GENE_LENGTH)]; //parse the bit string int num_elements = ParseBits(bits, buffer); for (int i=0; i<num_elements; i++) { PrintGeneSymbol(buffer[i]); } return; }