This certainly seems primed for pointers (and perhaps character literals):I don't suppose you could share the header with us?Code:if(toupper(input[32]) > 64 && toupper(input[32]) < 71) array[0] = (toupper(input[32]) - 55) * 16; else array[0] = (input[32] - 48) *16; if(toupper(input[33]) > 64 && toupper(input[33]) < 71) array[0] += (toupper(input[32]) - 55); else array[0] += input[33] - 48; if(toupper(input[34]) > 64 && toupper(input[34]) < 71) array[1] = (toupper(input[34]) - 55) *16; else array[1] = (input[34] - 48) *16; if(toupper(input[35]) > 64 && toupper(input[35]) < 71) array[1] += (toupper(input[35]) - 55); else array[1] += input[35] - 48;