trying to a string variable named hexnumber to convert each character (a through f ) to corresponding integer (10-15):
Code:
int input[100];//array of ints to store user's input digits
int i;
char j='a',k='A';
int u=10;//to convert a to 10 and increment when incrementing letters
//converting lowercase letters their corresponding integer of type int
while(j<='f')
{
i=0;
for(i=0;i<=(hexnumber.size()-2);i++)
{
if(hexnumber[2+i]==j||hexnumber[2+i]==k)
{input[i]=u;}
i++;
}
u++;
j++;
k++;
}
cout<<input[0]<<input[1];